---
title: "Create session"
method: POST
path: "/me/sessions"
tags: ["authentication"]
---

# Create session

`POST /me/sessions`

## Request

- Base URL: `https://localhost:8080/api/v9`
- URL: `https://localhost:8080/api/v9/me/sessions`
- Auth: none declared
- TypeScript: <https://skmtc.dev/toggl/apis/toggl-api/docs/me/sessions/post.ts> (a function with typed inputs; its response is checked against the schema)

Creates a session and sets a cookie in the response header which can be used for authentication in API requests

## Request body

- MePostSessionHandlerRequestBody
  - `remember_me` boolean: If true, the session cookie will be valid for 24 hours, otherwise until the browser is closed

## Response `200`

OK

- ModelsUser
  - `api_token` string: will be omitted if empty
  - `email` string, email
  - `fullname` string
  - `id` integer
  - `timezone` string

## Other responses

- `400`: Invalid JSON input

---

[API](https://skmtc.dev/toggl/apis/toggl-api.md) - [All operations](https://skmtc.dev/toggl/apis/toggl-api/llms.txt) - [OpenAPI document](https://skmtc.dev/toggl/apis/toggl-api/revisions/3085aee16990?raw)
