Skip to Content
Xeonr Developer Docs
API SpecificationFunctions

List functions

POST
/xeonr.functions.v2.FunctionsService/ListFunctions

Lists functions sorted by their hostname label (name), each with its activeVersion and latestVersion embedded so a status column needs no call per row. ownerTeam (a team URN or slug) narrows the listing to one team and needs the viewer role there; a team the caller is not in answers NOT_FOUND. Left empty, the listing covers every team in the caller's teams claim, or an API key's own team. search is a case-insensitive substring match on name.

Pages default to 50 functions and are capped at 500 (limit). Pass nextCursor back as cursor; an empty nextCursor means the last page. The cursor is opaque, and a function created during a paged walk can shift later pages. total counts every function matching ownerTeam and search across all pages, so a limit 1 request is enough to show a count.

Callable with a console session or a team API key (Authorization: Bearer xk_…).

Required scopes: functions:functions:read

Authorization

BearerAuth
AuthorizationBearer <token>

A team API key, created by a team admin in the console and presented as Authorization: Bearer xk_…. Xeonr Auth issues and verifies it; the secret is shown once at creation and stored only as a hash, and a revoked key stops working within 30 seconds. An existing fnt_… token is accepted the same way.

In: header

Header Parameters

Connect-Protocol-Version*number

Define the version of the Connect protocol

Value in1
Connect-Timeout-Ms?number

Define the timeout, in ms

Request Body

application/json

ownerTeam?string

owner_team scopes the listing to one team (URN or slug). Optional, and usefully so: empty means every team the caller can reach — their own memberships, or an API key's single team, which is what a CI caller always wants.

Match^[A-Za-z0-9:._-]*$
Lengthlength <= 255
search?string

search is a case-insensitive substring of the name, applied server-side so a command palette can search a large install without downloading it.

Lengthlength <= 128
cursor?string

cursor is a previous response's next_cursor; empty for the first page.

limit?integer

limit is the page size: 0 means the default of 50, at most 500.

Rangevalue <= 500
[key: string]?never

Response Body

application/json

application/json

curl -X POST "https://functions.xeonr.io/xeonr.functions.v2.FunctionsService/ListFunctions" \  -H "Connect-Protocol-Version: 1" \  -H "Content-Type: application/json" \  -d '{}'
{
  "functions": [
    "map[activeVersion:map[state:VERSION_STATE_READY versionId:v-7c1e04b9a2d35f68] activeVersionId:v-7c1e04b9a2d35f68 createdAt:2026-10-22T09:30:00Z displayName:Checkout API functionId:fn-3f9a2c71d4e8b605 kind:KIND_NODE latestVersion:map[state:VERSION_STATE_READY versionId:v-7c1e04b9a2d35f68] name:amber-heron-3f9a ownerTeam:urn:xeonr:auth:team:0f6b5f8c-3d2a-4c1e-9b7a-6e2d1c4f8a90 updatedAt:2026-10-23T09:30:00Z]"
  ],
  "nextCursor": "50",
  "total": "73"
}

Get a function POST

Returns one function by `functionId`, or by `name` (its assigned hostname label) when no id is given. One of the two is required (`INVALID_ARGUMENT`). The response embeds the active and latest versions, as `ListFunctions` does. Needs the viewer role in the owning team. An unknown function is `NOT_FOUND`; one in a team the caller cannot read is `PERMISSION_DENIED`. Callable with a console session or a team API key (`Authorization: Bearer xk_…`). **Required scopes:** `functions:functions:read`

Update a function POST

Applies a partial update: only the fields named in `updateMask` are written, and everything else is left alone. An empty mask is `INVALID_ARGUMENT`, and so is a path that is not writable: the writable paths are `display_name`, `owner_team`, `build`, `scaling`, `env`, `git_branch`, `git_subdirectory`, `git_access_token`, `git_webhook_secret`, `set_secrets` and `clear_secrets`. `displayName` is validated as at creation. `build` and `scaling` each replace their whole block when named. `env` replaces the whole map. `set_secrets` merges into the stored secrets and `clear_secrets` removes secrets by name; secret values are stored encrypted and only their names come back, in `secretKeys`. Settings that do not apply to the function's kind are refused with `INVALID_ARGUMENT`. `git_branch` and `git_subdirectory` change where a connected repository deploys from. A function with no repository is `FAILED_PRECONDITION`. `git_access_token` and `git_webhook_secret` are write-only: an empty string clears them. A running version keeps the environment it was created with, so env and secret changes go live with the next version (`CreateVersion` with a redeploy source). Needs the editor role in the owning team. Moving the function with `owner_team` also needs the admin role in the destination team. A `function.update` event records which settings and secret names changed, never their values. Callable with a console session or a team API key (`Authorization: Bearer xk_…`). **Required scopes:** `functions:functions:edit`