# Function does not exist when trying to invoke but deploy is successful

**URL:** <https://forum.serverless.com/t/function-does-not-exist-when-trying-to-invoke-but-deploy-is-successful/11366>\
**Category:** Serverless Framework\
**Tags:** google\
**Created:** [May 6, 2020, 11:03am UTC](https://forum.serverless.com/t/function-does-not-exist-when-trying-to-invoke-but-deploy-is-successful/11366 "2020-05-06T11:03:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![rnd\_dev](https://avatars.discourse-cdn.com/v4/letter/r/ed655f/32.png) [@rnd\_dev](https://forum.serverless.com/u/rnd_dev)\
**Post date:** [May 6, 2020, 11:03am UTC](https://forum.serverless.com/t/function-does-not-exist-when-trying-to-invoke-but-deploy-is-successful/11366/1 "2020-05-06T11:03:41Z")

</div>

This is probably something obvious but I can’t figure out this issue. So I just followed tutorial on settings up serverless with Google Cloud Functions. Deployment runs successfully, I see new function in the GCP portal and can execute it from there. But trying to execute it via serverless always fails with following error: `Error: Function paymentProviders in region europe-west3 in project *** does not exist`. I have tried changing both function name(I tried “payment-providers”, “paymentProviders” and just “providers”), I have tried changing handler name. Nothing worked for me. What am I missing?

---

<div class="post-metadata">

**Author:** ![keephopealive](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/keephopealive/32/4207_2.png) [@keephopealive](https://forum.serverless.com/u/keephopealive)\
**Post date:** [May 6, 2020, 3:40pm UTC](https://forum.serverless.com/t/function-does-not-exist-when-trying-to-invoke-but-deploy-is-successful/11366/2 "2020-05-06T15:40:31Z")

</div>

Hey rnd\_dev, can you share more information? What does the serverless.yaml file look like specifically for the function / environment and what command are you using to test the function? Any other relative information would be great to include. Obviously keep any sensitive/secure data out of the posts 🙂

---

<div class="post-metadata">

**Author:** ![rnd\_dev](https://avatars.discourse-cdn.com/v4/letter/r/ed655f/32.png) [@rnd\_dev](https://forum.serverless.com/u/rnd_dev)\
**Post date:** [May 6, 2020, 4:36pm UTC](https://forum.serverless.com/t/function-does-not-exist-when-trying-to-invoke-but-deploy-is-successful/11366/3 "2020-05-06T16:36:16Z")

</div>

I am using `serverless invoke --function providers`. Here is my current config:

```
service: market-intelligence
provider:
  name: google
  stage: dev
  runtime: nodejs10
  region: europe-west3
  project: project-name
  credentials: ~/.gcloud/key.json
plugins:
  - serverless-google-cloudfunctions
  - serverless-plugin-typescript

package:
   exclude:
     - node_modules/**
     - .gitignore
     - .git/**

   functions:
      providers:
         handler: getProviders
         events:
            - http: path

```

As for javascript file:

```
exports.getProviders = (request, response) => {
    response.status(200).send('Hello World!');
};

```

I am invoking function like this:

```
 serverless invoke --function providers
```
