# API reference

Every resource in the Enterprise API, one page per resource with the object model first and each operation beneath it.

> Enterprise API · https://developer.telgea.com/docs/enterprise/api

Each resource page opens with the object and every one of its fields, then lists every operation with its parameters, request body, responses and the permission its API key needs, beside an example panel that follows you down the page. Operations are labelled with the section they belong to: Enterprise API, Partner API, or both.

- [Users](https://developer.telgea.com/docs/enterprise/api/users): The people who hold a line: create them, keep their details current, and remove them when they leave.
- [Teams](https://developer.telgea.com/docs/enterprise/api/teams): Group users for billing, access control and reporting.
- [User plans](https://developer.telgea.com/docs/enterprise/api/user-plans): One person's line: provision it, look it up, replace a lost SIM and end it.
- [Port-ins](https://developer.telgea.com/docs/enterprise/api/port-ins): Bring a number from another carrier: discover the fields each country needs, validate, submit and track the port.
- [Usage](https://developer.telgea.com/docs/enterprise/api/usage): Raw voice, SMS and data records as one chronological feed.
- [Analytics](https://developer.telgea.com/docs/enterprise/api/analytics): Consumption aggregated per interval, for reporting and dashboards.
- [Data pools](https://developer.telgea.com/docs/enterprise/api/data-pools): How much of each shared pool is left, and what each member has used.
- [Rates](https://developer.telgea.com/docs/enterprise/api/rates): Pay-as-you-go prices for a market: calls and messages per destination, roaming data per visited country.

## Conventions [#conventions]

* Base URL: `https://api.telgea.com`
* Authentication: the `x-api-key` header on every request. Each operation names the permission its key needs.
* Identifiers are UUIDs; phone numbers are E.164; dates are `YYYY-MM-DD`; timestamps are ISO 8601 in UTC.
* Lists page with `page` (from 1) and `pageSize`, and return `itemsCount`, the total across pages. The usage feed pages with a cursor instead. Each operation states its own maximum page size.
* Every failure returns an RFC 9457 Problem Details body (`application/problem+json`) with `type`, `title`, `status`, `detail`, `code` and `requestId`; a validation failure adds `fields`, one entry per rejected field. See [Errors](https://developer.telgea.com/docs/enterprise/guides#error-handling).
* Each API key allows 1000 requests per 24 hours, shared across every endpoint; a request over the budget returns `429`.
* Every `POST`, `PATCH` and `DELETE` accepts an optional `Idempotency-Key` header, so a retry after a dropped connection returns the original response instead of doing the work twice.

## Try it [#try-it]

The [playground](https://developer.telgea.com/playground) lists every operation with a working example. There is no sandbox: calls run against your own live organization with your own key.

## Machine-readable description [#machine-readable-description]

The complete OpenAPI description, including every example on these pages: [`/openapi`](https://developer.telgea.com/openapi).
