> For the complete documentation index, see [llms.txt](https://docs.samesystem.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.samesystem.dev/api-v1-reference/session-authorization/post-client-token-login.md).

# Post Client Token Login

**Please notice:**

This is an older authentication method and we recommend using <https://api.samesystem.com/api/v/{clientToken}/**oauth/token>\*\*

Login to get a token for API authentication.

Received token should be encoded to *HTTP\_AUTHORISATION* header as token for all further API requests.

Token is valid for 15 minutes. When it expires, please re-login to get a new token.

```json
{"openapi":"3.0.0","info":{"title":"SameSystem API V1","version":"1.1.3"},"servers":[{"url":"https://api.samesystem.com/api/v1/","description":""}],"paths":{"/{clientToken}/login":{"post":{"tags":["Session authorization"],"summary":"","description":"**Please notice:**\n\nThis is an older authentication method and we recommend using\nhttps://api.samesystem.com/api/v/{clientToken}/**oauth/token**\n\n\nLogin to get a token for API authentication.\n\nReceived token should be encoded to *HTTP_AUTHORISATION* header as token for all further API requests.\n\nToken is valid for 15 minutes. When it expires, please re-login to get a new token.","operationId":"post-clientToken-login","parameters":[{"name":"clientToken","in":"path","description":"Token in a form of \"c\\<clientId\\>\".","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"required":["email","password"],"type":"object","properties":{"email":{"type":"string"},"password":{"type":"string"}}}}}},"responses":{"200":{"description":"Successful login","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string"},"token":{"type":"string"}}}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string"},"description":{"type":"string"}}}}}}}}}}}
```


---

# 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.samesystem.dev/api-v1-reference/session-authorization/post-client-token-login.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.
