You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -31,7 +31,7 @@ accurate comments, etc.) and any other requirements (such as test coverage).
31
31
5. Integration tests are separated out in another folder "/integration-tests". To run the integration test, you need to export the environment variables into the process env by doing the following :-
32
32
33
33
- Export `npm_config_projectkey` = `projectKey`,
34
-
- Export `CT_PROJECT_KEY`=`CLIENT_ID`:`CLIENT_SECRET` as specified [here](https://commercetools.github.io/nodejs/sdk/api/getCredentials.html).
34
+
- Export `CT_PROJECT_KEY`=`CLIENT_ID`:`CLIENT_SECRET` as specified [here](https://commercetools.github.io/nodejs/sdk/api/getCredentials).
35
35
- Then run integration test with `pnpm test:integration`
36
36
37
37
**Note: Due to the setup/teardown nature of the integration tests, there is the risk of potential data loss in your project**
Copy file name to clipboardExpand all lines: docs/cli/personal-data-erasure.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,7 @@ A package which deletes or exports [commercetools personal data](#list-of-person
16
16
The constructor accepts two arguments:
17
17
18
18
- A required object containing the following values:
19
-
-`apiConfig` (Object): `AuthMiddleware` options for authentication on the commercetools platform. (Required. See [here](https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareAuth.html#named-arguments-options))
19
+
-`apiConfig` (Object): `AuthMiddleware` options for authentication on the commercetools platform. (Required. See [here](https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareAuth#named-arguments-options))
20
20
-`accessToken` (String): [Access token] to be used to authenticate requests to API. Requires scope of [`view_products`, `manage_products`, `view_orders`, `manage_orders`, `view_payments`, `manage_payments`, `view_shopping_lists`, `manage_shopping_lists`, `view_customers`, `manage_customers`]. More info on how to get the access token [here](https://docs.commercetools.com/api/authorization)
21
21
- An optional logger object having four functions (`info`, `warn`, `error` and `debug`)
Copy file name to clipboardExpand all lines: docs/cli/resource-deleter.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -29,7 +29,7 @@ Examples of the resources are :
29
29
The constructor accepts two arguments:
30
30
31
31
- A required object containing the following values:
32
-
-`apiConfig` (Object): `AuthMiddleware` options for authentication on the commercetools platform. (Required. See [here](https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareAuth.html#named-arguments-options)).
32
+
-`apiConfig` (Object): `AuthMiddleware` options for authentication on the commercetools platform. (Required. See [here](https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareAuth#named-arguments-options)).
33
33
-`accessToken` (String): [Access token] to be used to authenticate requests to API. Requires scope of [`manage_products`, `manage_customers`, `manage_types`]. More info on how to get the access token [here](https://docs.commercetools.com/api/authorization).
34
34
-`resource` (String): [resource] that need to be deleted.
35
35
-`predicate` (String): Query string specifying (where) predicate. More info on predicates [here](https://docs.commercetools.com/api/predicates/query) (Optional).
Copy file name to clipboardExpand all lines: docs/sdk/api/typescriptSdk.md
+13-13Lines changed: 13 additions & 13 deletions
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@ Follow this [link](https://docs.commercetools.com/sdk/typescript-sdk) for an up
5
5
<!--
6
6
We provide a packages written in typescript for using our API
7
7
8
-
The **@commercetools/sdk-client-v2** is the TypeScript package that facilitates HTTP [requests](https://commercetools.github.io/nodejs/sdk/Glossary.html#clientrequest) to the Platform, ML or History API by using a predefined set of middlewares.
8
+
The **@commercetools/sdk-client-v2** is the TypeScript package that facilitates HTTP [requests](https://commercetools.github.io/nodejs/sdk/Glossary#clientrequest) to the Platform, ML or History API by using a predefined set of middlewares.
9
9
10
10
Unlike the Node.js sdk-client, the TypeScript client is a little different in its usage however, they are both very similar in every other aspect and it's also backward compatible with the Nodejs sdk-client.
11
11
@@ -342,7 +342,7 @@ These are class methods that creates auth middlewares using different authentica
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to handle authentication for the [Anonymous Session](https://docs.commercetools.com/http-api-authorization.html#tokens-for-anonymous-sessions) flow of the commercetools Platform API.
345
+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to handle authentication for the [Anonymous Session](https://docs.commercetools.com/api/authorization#tokens-for-anonymous-sessions) flow of the commercetools Platform API.
346
346
347
347
#### Named arguments (options)
348
348
@@ -379,7 +379,7 @@ const client: Client = new ClientBuilder()
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to handle authentication for the Client [Credentials Flow](https://docs.commercetools.com/http-api-authorization.html#client-credentials-flow) of the commercetools platform API.
382
+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to handle authentication for the Client [Credentials Flow](https://docs.commercetools.com/api/authorization#client-credentials-flow) of the commercetools platform API.
383
383
384
384
#### Named arguments (options)
385
385
@@ -417,7 +417,7 @@ const client: Client = new ClientBuilder()
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) that attaches a provided access token `Authorization` header.
420
+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) that attaches a provided access token `Authorization` header.
421
421
422
422
#### Named arguments (authorization, options)
423
423
@@ -446,7 +446,7 @@ const client: Client = new ClientBuilder()
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to handle authentication for the [Password Flow](https://docs.commercetools.com/http-api-authorization.html#password-flow) of the commercetools platform API.
449
+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to handle authentication for the [Password Flow](https://docs.commercetools.com/api/authorization#password-flow) of the commercetools platform API.
450
450
451
451
#### Named arguments (options)
452
452
@@ -488,7 +488,7 @@ const client: Client = new ClientBuilder()
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to handle authentication for the Refresh Token Flow of the commercetools platform API.
491
+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to handle authentication for the Refresh Token Flow of the commercetools platform API.
492
492
493
493
#### Named arguments (options)
494
494
@@ -528,7 +528,7 @@ There are other class methods that creates middlewares used to fully customize a
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to handle HTTP requests for the commercetools platform API.
531
+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to handle HTTP requests for the commercetools platform API.
532
532
533
533
The HTTP middleware can run in either a browser or Node.js environment. For Node.js environments it is important to either have a fetch implementation either globally available via e.g. [isomorphic-fetch](https://github.com/matthew-andrews/isomorphic-fetch) or to pass it in as an argument (see below) via e.g. [node-fetch](https://github.com/bitinn/node-fetch). In browsers without a native fetch implementation any well known fetch polyfill should be compatible with the middleware such as [whatwg-fetch](https://github.com/whatwg/fetch) or [unfetch](https://github.com/developit/unfetch).
534
534
@@ -623,12 +623,12 @@ This is to ensure that a new instance of the AbortController is always created a
623
623
624
624
##### getErrorByCode(code)
625
625
626
-
Returns a [custom error](https://commercetools.github.io/nodejs/sdk/Glossary.html#httperrortype) type given its status code.
626
+
Returns a [custom error](https://commercetools.github.io/nodejs/sdk/Glossary#httperrortype) type given its status code.
627
627
628
628
Arguments
629
629
`code` (_Number_): the HTTP status code
630
630
Returns
631
-
(`Error` or `undefined`): A [custom error](https://commercetools.github.io/nodejs/sdk/Glossary.html#httperrortype) type (e.g. `BadRequest`, `Unauthorized`) if the code matches, otherwise `undefined`.
631
+
(`Error` or `undefined`): A [custom error](https://commercetools.github.io/nodejs/sdk/Glossary#httperrortype) type (e.g. `BadRequest`, `Unauthorized`) if the code matches, otherwise `undefined`.
632
632
633
633
#### Usage example
634
634
@@ -643,7 +643,7 @@ const error = new ErrorType('Oops')
643
643
644
644
#### withUserAgentMiddleware()
645
645
646
-
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to append the `User-Agent` HTTP header to the request.
646
+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to append the `User-Agent` HTTP header to the request.
647
647
648
648
#### Usage example
649
649
@@ -662,7 +662,7 @@ const client: Client = new ClientBuilder()
0 commit comments