> For the complete documentation index, see [llms.txt](https://docs.payments.thalescloud.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.payments.thalescloud.io/instant-issuance/instant-issuance-ja/d1-apiwosuru/d1-apirifarensu/autobaundoapid1kara/d1-oauth-api.md).

# D1 OAuth API

## Get Authorization Token

> This request is used by Thales to retrieve an OAUTH 2.0 access authorization token to be used for outgoing issuer API requests.

```json
{"openapi":"3.0.0","info":{"title":"D1 OAuth API","version":"1.0"},"servers":[{"url":"https://YOUR_DOMAIN/authz/d1/v1"}],"paths":{"/oauth2/token":{"post":{"description":"This request is used by Thales to retrieve an OAUTH 2.0 access authorization token to be used for outgoing issuer API requests.","parameters":[{"schema":{"type":"string"},"in":"header","name":"authorization","description":"The authorization header includes a client secret in base64URL encoded format following this syntax: Basic \"[clientId:client secret]\" as per https://www.rfc-editor.org/rfc/rfc2617","required":true}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/auth2Request"}}}},"responses":{"200":{"description":"Default allowed response","content":{"application/json":{"schema":{"type":"object","properties":{"access_token":{"type":"string","description":"The access token issued by the authorization server","readOnly":true},"expires_in":{"type":"string","description":"Remaining time in seconds for the access_token to expire.","readOnly":true},"scope":{"type":"string","description":"Scope of the access_token.","readOnly":true},"token_type":{"description":"Type of the access_token that will be used to call Issuer APIs.","enum":["Bearer"]},"expires_at":{"type":"string","description":"Access token expiration timestamp","readOnly":true}},"required":["access_token","token_type"]}}}},"400":{"description":"Bad request"}},"summary":"Get Authorization Token","operationId":"getAccessToken"}}},"components":{"schemas":{"auth2Request":{"type":"object","title":"Authorization request body","properties":{"grant_type":{"type":"string","enum":["client_credentials"]},"scope":{"description":"Access request scope as optionally defined by the issuer ","type":"string"}},"required":["grant_type"]}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.payments.thalescloud.io/instant-issuance/instant-issuance-ja/d1-apiwosuru/d1-apirifarensu/autobaundoapid1kara/d1-oauth-api.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
