Skip to content
Luna
Esc
↑↓navigate↵open⌘Jpreview

Update an organisation

Changes an organisation’s name, its slug or both. A new slug changes the organisation’s address in every path. Answers 409 when you are already in another organisation of the new name. An API key cannot do this.

PATCH/_luna/orgs/{org}
Authorization
AuthorizationBearer token · headerrequired

An account key (la_…), an API key (lt_…) or a session token (ls_…). The scopes listed are the permissions the operation needs.

Scopes:organisation:write
Path parameters
orgstringrequired

The organisation, by its slug.

Request body
requiredapplication/json
slugstring | null

A new slug: lower-case letters, digits and single dashes. Paths use it from then on.

default: null
namestring | null

A new name.

default: null
Responses
200

The organisation as it is now.

idstringrequired
slugstringrequired

The name paths use for it. Luna makes it from the name.

namestringrequired
createdMsinteger<int64>required
min 0
default

The request failed. The status says how and error.message says why.

errorErrorDetailrequired
Show properties
codestring | null

A code for programs to branch on, when the error has one.

messagestringrequired

What went wrong, in a sentence a person can read.

Try it
Server
Authorization
Parameters
Bodyapplication/json
Request
curl -X PATCH 'https://luna.example.com/_luna/orgs/string' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "slug": null,
  "name": null
}'
Response
{
  "id": "string",
  "slug": "string",
  "name": "string",
  "createdMs": 0
}

Was this page helpful?