# Token denied. Request lacks valid authentication credentials

**URL:** <https://discourse.chef.io/t/token-denied-request-lacks-valid-authentication-credentials/13072>\
**Category:** Chef Automate\
**Created:** [May 15, 2018, 2:51pm UTC](https://discourse.chef.io/t/token-denied-request-lacks-valid-authentication-credentials/13072 "2018-05-15T14:51:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![nicknameyu](https://avatars.discourse-cdn.com/v4/letter/n/e47774/32.png) [@nicknameyu](https://discourse.chef.io/u/nicknameyu)\
**Post date:** [May 15, 2018, 2:51pm UTC](https://discourse.chef.io/t/token-denied-request-lacks-valid-authentication-credentials/13072/1 "2018-05-15T14:51:04Z")

</div>

I’m trying to configure my Chef workstation with Chef automate. I configured my user account in Chef Automate as admin, committer, reviewer, shipper, observer; SSH key configured as well. cli.toml config as following(I replaced the user and enterprise value for security consideration):

```auto
server = " ***********************"
api_protocol = "https"
user = " ***********************"
enterprise = " ***********"
organization = "TestOrganization"
git_port = "8989"
pipeline = "master"

```

When I generate a cookbook and run delivery init, it came back token denied.

```auto
PS C:\users\ ****** \chef-repo\workflow\ydk-test-automate> delivery init
Chef Delivery
Requesting Token
Press Enter to open a browser window to retrieve a new token.
Launching browser..
Enter token: xOBAs8HwEl5f1i8t-2lvAG_XlPJykhS1GlZtX_H3swM
token: xOBAs8HwEl5f1i8t-2lvAG_XlPJykhS1GlZtX_H3swM
saved API token to: C:\Users\yudongkadm\.delivery\api-tokens
token: xOBAs8HwEl5f1i8t-2lvAG_XlPJykhS1GlZtX_H3swM
Verifying Token: valid
Creating Delivery project...
401: Authentication failed
Request lacks valid authentication credentials.
Detail:
{
  "error": "token_denied"
}

Any other configuration I missed?
```
