chore(docs): Updated API Reference (#3107)

* chore(docs): Generated API Reference

* small fix

Co-authored-by: olivermrbl <olivermrbl@users.noreply.github.com>
Co-authored-by: Shahed Nasser <shahednasser@gmail.com>
This commit is contained in:
github-actions[bot]
2023-01-25 10:28:11 +02:00
committed by GitHub
parent 0312eceda7
commit 4e82ec0734
3 changed files with 51 additions and 12 deletions

View File

@@ -543,17 +543,30 @@ components:
of `{api_token}`. This is where you must pass the API token.
If you're alternatively following along with the JS Client request
samples, you must provide the `apiKey` option when creating the Medusa
client:
If you're following along with the JS Client request samples, you must
provide the `apiKey` option when creating the Medusa client:
```js
```ts
const medusa = new Medusa({ baseUrl: MEDUSA_BACKEND_URL, maxRetries: 3,
apiKey: '{api_token}' })
```
If you're using Medusa React, you can pass the `apiKey` prop to
`MedusaProvider`:
```tsx
<MedusaProvider
apiKey='{api_token}'
//...
>
```
scheme: bearer
cookie_auth:
type: apiKey