---
title: "Create a new Service Account"
method: POST
path: "/ServiceAccounts"
tags: ["Serviceaccounts"]
---

# Create a new Service Account

`POST /ServiceAccounts`

**Requires permission:** *IT*

These Service Accounts are used to authenticate with the APIs and Access Single Pages within the App

## Query parameters

- `page` integer, required
- `pageSize` integer, required
- `includes` string[], nullable
- `sort` string, nullable
- `filter` string, nullable

## Request body

- PostServiceAccountRequest
  - `serviceAccount` ServiceAccount
    - `id` string, guid
    - `displayName` string, nullable
    - `purpose` string, nullable
    - `clientId` string, nullable
    - `clientSecret` string, nullable
    - `permissions` string, nullable
    - `appAccess` boolean
    - `appLink` string, nullable
    - `allowedApis` string, nullable
    - `active` boolean
    - `tokenLifetimeSeconds` integer, nullable
    - `lastUsed` string, date-time, nullable
    - `allowedApisList` string[]

## Response `200`

Success - Service Account Created and ClientId & Secret Returned

- PostServiceAccountResponse
  - `clientId` string, nullable
  - `clientSecret` string, nullable
  - `meta` Meta
    - `page` integer
    - `pageSize` integer
    - `total` integer

## Other responses

- `400` — An Error Occurred - Could not create Service Account
- `401` — Unauthorized
- `403` — Forbidden

---

[API](https://skmtc.net/tonbridge/apis/tonbridge-app-api.md) · [All operations](https://skmtc.net/tonbridge/apis/tonbridge-app-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/tonbridge/tonbridge-app-api/versions/fab57bf5558a/schema)
