Skip to content

Commit 6fe114e

Browse files
industriantdeekens
andauthored
Update links (#1949)
* Update links * Create strange-insects-grin.md --------- Co-authored-by: Tobias Deekens <[email protected]>
1 parent d79d013 commit 6fe114e

File tree

25 files changed

+56
-38
lines changed

25 files changed

+56
-38
lines changed

.changeset/strange-insects-grin.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
"@commercetools/api-request-builder": patch
3+
"@commercetools/get-credentials": patch
4+
"@commercetools/http-user-agent": patch
5+
"@commercetools/personal-data-erasure": patch
6+
"@commercetools/resource-deleter": patch
7+
"@commercetools/sdk-auth": patch
8+
"@commercetools/sdk-client": patch
9+
"@commercetools/sdk-middleware-auth": patch
10+
"@commercetools/sdk-middleware-correlation-id": patch
11+
"@commercetools/sdk-middleware-http": patch
12+
"@commercetools/sdk-middleware-logger": patch
13+
"@commercetools/sdk-middleware-queue": patch
14+
"@commercetools/sdk-middleware-user-agent": patch
15+
"@commercetools/sync-actions": patch
16+
---
17+
18+
Update links to documentation.

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ accurate comments, etc.) and any other requirements (such as test coverage).
3131
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 :-
3232

3333
- 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).
3535
- Then run integration test with `pnpm test:integration`
3636

3737
**Note: Due to the setup/teardown nature of the integration tests, there is the risk of potential data loss in your project**

docs/cli/personal-data-erasure.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ A package which deletes or exports [commercetools personal data](#list-of-person
1616
The constructor accepts two arguments:
1717

1818
- 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))
2020
- `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)
2121
- An optional logger object having four functions (`info`, `warn`, `error` and `debug`)
2222

docs/cli/resource-deleter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Examples of the resources are :
2929
The constructor accepts two arguments:
3030

3131
- 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)).
3333
- `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).
3434
- `resource` (String): [resource] that need to be deleted.
3535
- `predicate` (String): Query string specifying (where) predicate. More info on predicates [here](https://docs.commercetools.com/api/predicates/query) (Optional).

docs/sdk/api/typescriptSdk.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Follow this [link](https://docs.commercetools.com/sdk/typescript-sdk) for an up
55
<!--
66
We provide a packages written in typescript for using our API
77
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.
99
1010
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.
1111
@@ -342,7 +342,7 @@ These are class methods that creates auth middlewares using different authentica
342342
343343
#### withAnonymousSessionFlow(options: _AnonymousAuthMiddlewareOptions_)
344344
345-
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.
346346
347347
#### Named arguments (options)
348348
@@ -379,7 +379,7 @@ const client: Client = new ClientBuilder()
379379
380380
#### withClientCredentialsFlow(options: _AuthMiddlewareOptions_)
381381
382-
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.
383383
384384
#### Named arguments (options)
385385
@@ -417,7 +417,7 @@ const client: Client = new ClientBuilder()
417417
418418
#### withExistingTokenFlow(authorization: _string_, options: _ExistingTokenMiddlewareOptions_)
419419
420-
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.
421421
422422
#### Named arguments (authorization, options)
423423
@@ -446,7 +446,7 @@ const client: Client = new ClientBuilder()
446446
447447
#### withPasswordFlow(options: _PasswordAuthMiddlewareOptions_)
448448
449-
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.
450450
451451
#### Named arguments (options)
452452
@@ -488,7 +488,7 @@ const client: Client = new ClientBuilder()
488488
489489
#### withRefreshTokenFlow(options: _RefreshAuthMiddlewareOptions_)
490490
491-
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.
492492
493493
#### Named arguments (options)
494494
@@ -528,7 +528,7 @@ There are other class methods that creates middlewares used to fully customize a
528528
529529
#### withHttpMiddleware(options: _HttpMiddlewareOptions_)
530530
531-
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.
532532
533533
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).
534534
@@ -623,12 +623,12 @@ This is to ensure that a new instance of the AbortController is always created a
623623
624624
##### getErrorByCode(code)
625625
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.
627627
628628
Arguments
629629
`code` (_Number_): the HTTP status code
630630
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`.
632632
633633
#### Usage example
634634
@@ -643,7 +643,7 @@ const error = new ErrorType('Oops')
643643
644644
#### withUserAgentMiddleware()
645645
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.
647647
648648
#### Usage example
649649
@@ -662,7 +662,7 @@ const client: Client = new ClientBuilder()
662662
663663
#### withCorrelationIdMiddleware(options: _CorrelationIdMiddlewareOptions_)
664664
665-
Creates a middleware to add a correlation ID to executed [requests](https://commercetools.github.io/nodejs/sdk/Glossary.html#clientrequest).
665+
Creates a middleware to add a correlation ID to executed [requests](https://commercetools.github.io/nodejs/sdk/Glossary#clientrequest).
666666
667667
#### Usage example
668668
@@ -683,7 +683,7 @@ const client: Client = new ClientBuilder()
683683
684684
#### withQueueMiddleware(options: _QueueMiddlewareOptions_)
685685
686-
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to handle concurrent requests.
686+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to handle concurrent requests.
687687
688688
#### Named arguments (options)
689689
@@ -707,7 +707,7 @@ const client: Client = new ClientBuilder()
707707
708708
#### withLoggerMiddleware()
709709
710-
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary.html#middleware) to log request and response objects being executed.
710+
Creates a [middleware](https://commercetools.github.io/nodejs/sdk/Glossary#middleware) to log request and response objects being executed.
711711
712712
#### Usage Example
713713

packages/api-request-builder/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Helper functions collection to easily construct API requests URI in a declarative way, for usage with `@commercetools/sdk-client`.
44

5-
https://commercetools.github.io/nodejs/sdk/api/apiRequestBuilder.html
5+
https://commercetools.github.io/nodejs/sdk/api/apiRequestBuilder
66

77
## Install
88

packages/get-credentials/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"type": "git",
1717
"url": "https://github.com/commercetools/nodejs/tree/master/packages/get-credentials"
1818
},
19-
"homepage": "https://commercetools.github.io/nodejs/sdk/api/getCredentials.html",
19+
"homepage": "https://commercetools.github.io/nodejs/sdk/api/getCredentials",
2020
"bugs": "https://github.com/commercetools/nodejs/issues",
2121
"license": "MIT",
2222
"contributors": [

packages/get-credentials/readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Retrieve commercetools platform credentials from environment variables or file system.
1414

15-
https://commercetools.github.io/nodejs/sdk/api/getCredentials.html
15+
https://commercetools.github.io/nodejs/sdk/api/getCredentials
1616

1717
## Install
1818

packages/http-user-agent/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Creates a proper HTTP User-Agent
1414

15-
https://commercetools.github.io/nodejs/sdk/api/httpUserAgent.html
15+
https://commercetools.github.io/nodejs/sdk/api/httpUserAgent
1616

1717
## Install
1818

packages/personal-data-erasure/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"type": "git",
1919
"url": "https://github.com/commercetools/nodejs/tree/master/packages/personal-data-erasure"
2020
},
21-
"homepage": "https://commercetools.github.io/nodejs/cli/personal-data-erasure.html",
21+
"homepage": "https://commercetools.github.io/nodejs/cli/personal-data-erasure",
2222
"bugs": "https://github.com/commercetools/nodejs/issues",
2323
"keywords": [
2424
"commercetools",

packages/resource-deleter/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"type": "git",
1919
"url": "https://github.com/commercetools/nodejs/tree/master/packages/resource-deleter"
2020
},
21-
"homepage": "https://commercetools.github.io/nodejs/cli/resource-deleter.html",
21+
"homepage": "https://commercetools.github.io/nodejs/cli/resource-deleter",
2222
"bugs": "https://github.com/commercetools/nodejs/issues",
2323
"keywords": [
2424
"commercetools",

packages/resource-deleter/readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Deletes commercetools resources from the commercetools platform.
44

5-
More info here: https://commercetools.github.io/nodejs/cli/resource-deleter.html
5+
More info here: https://commercetools.github.io/nodejs/cli/resource-deleter
66

77
## Install
88

packages/sdk-auth/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Auth module for working with commercetools platform API
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkAuth.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkAuth
1616

1717
## Install
1818

packages/sdk-client/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
SDK Client for usage of commercetools platform API
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkClient.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkClient
1616

1717
## Note:
1818

packages/sdk-client/src/client.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ export default function createClient(options: ClientOptions): Client {
8888
if (typeof fn !== 'function')
8989
// eslint-disable-next-line max-len
9090
throw new Error(
91-
'The "process" function accepts a "Function" as a second argument that returns a Promise. See https://commercetools.github.io/nodejs/sdk/api/sdkClient.html#processrequest-processfn-options'
91+
'The "process" function accepts a "Function" as a second argument that returns a Promise. See https://commercetools.github.io/nodejs/sdk/api/sdkClient#processrequest-processfn-options'
9292
)
9393

9494
// Set default process options

packages/sdk-client/src/validate.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,18 @@ export default function validate(
88
if (!request)
99
// eslint-disable-next-line max-len
1010
throw new Error(
11-
`The "${funcName}" function requires a "Request" object as an argument. See https://commercetools.github.io/nodejs/sdk/Glossary.html#clientrequest`
11+
`The "${funcName}" function requires a "Request" object as an argument. See https://commercetools.github.io/nodejs/sdk/Glossary#clientrequest`
1212
)
1313

1414
if (typeof request.uri !== 'string')
1515
// eslint-disable-next-line max-len
1616
throw new Error(
17-
`The "${funcName}" Request object requires a valid uri. See https://commercetools.github.io/nodejs/sdk/Glossary.html#clientrequest`
17+
`The "${funcName}" Request object requires a valid uri. See https://commercetools.github.io/nodejs/sdk/Glossary#clientrequest`
1818
)
1919

2020
if (!options.allowedMethods.includes(request.method))
2121
// eslint-disable-next-line max-len
2222
throw new Error(
23-
`The "${funcName}" Request object requires a valid method. See https://commercetools.github.io/nodejs/sdk/Glossary.html#clientrequest`
23+
`The "${funcName}" Request object requires a valid method. See https://commercetools.github.io/nodejs/sdk/Glossary#clientrequest`
2424
)
2525
}

packages/sdk-middleware-auth/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Auth middlewares collection for usage with `@commercetools/sdk-client`
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareAuth.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareAuth
1616

1717
### Install
1818

packages/sdk-middleware-correlation-id/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Middleware for adding a correlation id to requests with `@commercetools/sdk-client`
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareCorrelationId.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareCorrelationId
1616

1717
## Install
1818

packages/sdk-middleware-http/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Middleware for making http requests for usage with `@commercetools/sdk-client`
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareHttp.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareHttp
1616

1717
## Install
1818

packages/sdk-middleware-logger/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Middleware for queueing requests for usage with `@commercetools/sdk-client`
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareLogger.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareLogger
1616

1717
## Install
1818

packages/sdk-middleware-queue/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Middleware for queueing requests for usage with `@commercetools/sdk-client`
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareQueue.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareQueue
1616

1717
## Install
1818

packages/sdk-middleware-user-agent/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
Middleware for setting the User-Agent on the HTTP request for usage with `@commercetools/sdk-client`
1414

15-
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareUserAgent.html
15+
https://commercetools.github.io/nodejs/sdk/api/sdkMiddlewareUserAgent
1616

1717
## Install
1818

packages/sync-actions/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Construct API update actions, for usage with `@commercetools/sdk-client`.
44

5-
https://commercetools.github.io/nodejs/sdk/api/syncActions.html
5+
https://commercetools.github.io/nodejs/sdk/api/syncActions
66

77
## Install
88

packages/sync-actions/src/types-actions.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ export function actionsMapFieldDefinitions(
201201
// Make sure to execute removeActions before creating new ones
202202
// in order to prevent any eventual removal of `addAction`.
203203
// List of `removeActions` can be found here
204-
// https://docs.commercetools.com/http-api-projects-types.html#change-key
204+
// https://docs.commercetools.com/api/projects/types#change-key
205205
const sortedActions = sortBy(
206206
actions,
207207
(action) => action.action !== 'removeFieldDefinition'

packages/sync-actions/test/product-types-sync-attribute-hints.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ describe('product type hints', () => {
238238
newValue: {
239239
key: 'next-enum-draft-item',
240240
// this is a possibility on clients. we ought to rely on the API, to return an error
241-
// ref: https://docs.commercetools.com/http-api-projects-productTypes.html#change-the-label-of-an-enumvalue
241+
// ref: https://docs.commercetools.com/api/projects/productTypes#change-the-label-of-an-enumvalue
242242
label: undefined,
243243
},
244244
},

0 commit comments

Comments
 (0)