# Provided ARN for resourse is invalid with serverless-step-function

**URL:** <https://forum.serverless.com/t/provided-arn-for-resourse-is-invalid-with-serverless-step-function/1733>\
**Category:** Serverless Framework\
**Created:** [April 19, 2017, 8:29pm UTC](https://forum.serverless.com/t/provided-arn-for-resourse-is-invalid-with-serverless-step-function/1733 "2017-04-19T20:29:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kararade](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/kararade/32/602_2.png) [@kararade](https://forum.serverless.com/u/kararade)\
**Post date:** [April 19, 2017, 8:29pm UTC](https://forum.serverless.com/t/provided-arn-for-resourse-is-invalid-with-serverless-step-function/1733/1 "2017-04-19T20:29:07Z")

</div>

hey guys!

I’m getting an error with the following data using the serverless-step-function plugin [GitHub - serverless-operations/serverless-step-functions at 0.4.2](https://github.com/horike37/serverless-step-functions/tree/0.4.2)  
{“error”:“States.Runtime”,“cause”:“An error occurred while scheduling the state ‘CreatePhotoDocument’. The provided ARN ‘create’ is invalid.”}

 ![](https://canada1.discourse-cdn.com/flex036/uploads/serverless/original/1X/0974c9ed42892341c4694ea1393b533f709501d7.png)

This is part of my YML file

```
provider:
  iamRoleStatements:
    - Effect: Allow
      Action:
        - states:*
      Resource: "*"

functions:
  create:
    handler: handler.create
  resize:
    handler: handler.resize

stepFunctions:
  stateMachines:
    photoResizeWatermark:
      events:
        - http:
            path: ''
            method: POST
            cors: true
      definition:
        StartAt: CreatePhotoDocument
        States:
          CreatePhotoDocument:
            Type: Task
            Resource: create
            Next: ResizeThumbAndPreview
          ResizeThumbAndPreview:
            Type: Task
            Resource: resize
            End: true

```

Could you give me a hand on this guys?

Thanks

---

<div class="post-metadata">

**Author:** ![kararade](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/kararade/32/602_2.png) [@kararade](https://forum.serverless.com/u/kararade)\
**Post date:** [April 19, 2017, 9:07pm UTC](https://forum.serverless.com/t/provided-arn-for-resourse-is-invalid-with-serverless-step-function/1733/2 "2017-04-19T21:07:52Z")

</div>

my mistake.

this is what I’m needing  
`Resource: arn:aws:lambda:${opt:region}:${self:custom.accountId}:function:${self:service}-${opt:stage}-hello`

Thanks guys!

---

<div class="post-metadata">

**Author:** ![walshe](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/walshe/32/1032_2.png) [@walshe](https://forum.serverless.com/u/walshe)\
**Post date:** [March 6, 2018, 9:38pm UTC](https://forum.serverless.com/t/provided-arn-for-resourse-is-invalid-with-serverless-step-function/1733/3 "2018-03-06T21:38:32Z")

</div>

where is th best place to define step functions ?

a) in the serverless.yml that the client of the step function is ?

b) in the serverless.yml of the stack that contains the step functions (which may not be possible if they exist across a couple of separate stacks)

c) in a separate ‘step-functions’ serverless project altogether. And in here the step functions might use lambdas in many other stacks
