Docs

Type a word or a question. Esc closes the search.

Sign in Start free

Create a client

Creates a Client with optional portal access, localization, branding, and a template that can create monitors or status pages.

POST https://app.upfour.io/v1/clients
POST https://app.upfour.io/v1/clients

A real request. What it creates runs in your up4 account and uses credit, like anything you add in the app.

Authorization
AuthorizationA pls_ key. It stays in this browser tab. Needs client.write.
Body
language The language of mails and documents for this client; null or empty inherits the company default.
Portal access1
allow_login Lets the client's own staff sign in to the client portal. Without it the client only has share links.
Template application2
Logo1
Idempotency1

2 more fields are only available in JSON.

Headers

Sent directly from your browser to https://app.upfour.io/v1. Mutating calls get an automatic Idempotency-Key when the field is empty.

Request
Responsenot sent yet
Fill in a key and press Send request (⌘↵).
The answer appears here.
scope client.write stable Idempotency-Key supported returns 201

Body

The 5 fields most calls use come first; the rest are grouped below.

application/json required 12 fields

namestringrequired
In the app: Client name
slugstring

Lowercase letters, digits and hyphens; derived from the name when empty.

contact_emailstring
languagestring · nullable

The language of mails and documents for this client; null or empty inherits the company default.

ende
In the app: Communication language
timezonestring

IANA timezone name; empty takes the company's reporting timezone.

Portal access1 fields
allow_loginboolean

Lets the client's own staff sign in to the client portal. Without it the client only has share links.

In the app: Let this client sign in
Template application3 fields
template_idstring

A client template to apply to the new client.

In the app: Starter template
domainstring

The client's domain for the template's {{domain}} placeholder. Required when the template uses it.

In the app: Primary domain
design_template_revisionsmap of integer

Maps the id of each status page design the template uses to the revision you saw; the create stops with a conflict when a design changed since.

Logo6 fields
logo_urlstring

A hosted logo, http:// or https://. Saving a standard logo clears it.

Idempotency1 fields
creation_keyuuid · nullable

Idempotency key: creating again with the same key returns the client that exists instead of a second one.

Returns

A successful request returns 201 with application/json.

Response fields 1 top-level fields
FieldTypeDescription
data ClientCreateResponse
ClientCreateResponse · 42 fields
FieldTypeDescription
allow_login boolean
contact_email string
created_at string (date-time)
id uuid
language string · nullable one ofende
logo StoredClientLogo
StoredClientLogo · 4 fields
FieldTypeDescription
background string one oflightdarktransparent The background the logo is made for.
dark string Same as standard, for dark backgrounds. Needs a standard logo.
icon string Same as standard, for compact places. Needs a standard logo.
standard string Request: a PNG as data:image/png;base64,... of at most 192 KiB, or the value the client already has to keep that image; empty removes it. Response: the path of the stored image.
logo_url string A hosted logo; empty once a standard logo is stored.
name string
organization_id uuid
slug string
timezone string
updated_at string (date-time)
archived_at string (date-time) Set while the client is archived.
effective_language string one ofende Only in the answer for one client: the language the client actually gets, its own or the company default.
materialization MaterializeResult
MaterializeResult · 21 fields
FieldTypeDescription
monitors_created integer
policies_created integer
status_pages_created integer
errors MaterializeError[]
Each item · 3 fields
FieldTypeDescription
kind string one oftemplatemonitormonitor_alarm_routepolicystatus_page
message string
name string
monitors MaterializedMonitor[]
Each item · 8 fields
FieldTypeDescription
alarm_route_status string one ofconfiguredwithout_alarm_route
id uuid
name string
channels MaterializedChannel[]
Each item · 4 fields
FieldTypeDescription
id uuid
name string
scope string
type string
status_pages MaterializedStatusPage[]
Each item · 4 fields
FieldTypeDescription
id uuid
is_published boolean
name string
subdomain string
monitor_count integer Only in lists, omitted when zero.
open_incidents integer Only in lists, omitted when zero.

Errors

Only the errors this operation can return. Every error uses the same envelope.

Status Code Meaning
400 bad_request The request is malformed or fails validation.
403 check_capacity_exceeded For subscriptions, the change would raise projected 30-day monitor usage above the included check budget; error.details gives projected, included and change costs. When: Creating a monitor, directly or through a client template, or changing one, when the projected cost including the change exceeds the budget; running monitors are not affected, and details carries projected_cents, included_cents and change_cents. Fix: Use a longer interval, fewer regions or fewer monitors, or raise the included budget. check_capacity_exceeded (subscriptions only): the change would raise the projected 30-day list usage of all active monitors above the included check budget. error.details carries projected_cents, included_cents and change_cents; a longer interval, fewer regions or fewer monitors fit. Running monitors and changes that lower the load are never refused.
409 design_template_conflict The design template was changed after the caller read it. When: Updating or applying a design template that was changed after the caller read it. Fix: Reload the template and apply the change again.
404 design_template_not_found The design template does not exist or is not visible to the caller. When: A design template id in the path or body that is unknown or not visible to the caller. Fix: List design templates and use an id from the list.
400 file_empty The uploaded logo file is empty. When: Uploading a logo or image with no content. Fix: Upload a file that has content. Stable codes next to the English message when a logo is refused: file_empty, file_type_unsupported (error.details.formats lists the accepted ones), image_invalid (damaged or unreadable), image_dimensions_too_large (error.details.max_pixels), svg_unsafe.
413 file_too_large The logo file exceeds its size limit; error.details.max_bytes gives the limit. When: Uploading a logo or image larger than details.max_bytes. Fix: Reduce the file size and upload again. file_too_large: the file is over its limit (error.details.max_bytes). A proxy in front of the API may answer 413 with a plain HTML body and no code.
400 file_type_unsupported The uploaded logo file type is unsupported; error.details.formats lists accepted formats. When: Uploading a file whose type is not one of the formats the operation accepts; details.formats lists them. Fix: Upload a file in one of details.formats.
400 image_dimensions_too_large The logo image exceeds the allowed dimensions; error.details.max_pixels gives the limit. When: Uploading an image with more pixels than details.max_pixels. Fix: Scale the image down and upload it again.
400 image_invalid The uploaded logo image is damaged or unreadable. When: Uploading a file with an image type that cannot be decoded. Fix: Export the image again and upload the new file.
400 logo_fetch_failed The logo could not be fetched from the address given. When: Importing a client logo from a URL that cannot be reached or that does not return an acceptable image. Fix: Check the URL, or upload the logo file instead.
404 not_found The requested resource does not exist or is outside the caller's scope.
403 permission_denied The credentials do not permit this action.
400 svg_unsafe The SVG logo contains unsafe content. When: Uploading an SVG that contains a script, a foreignObject, a javascript: URL, an event-handler attribute or an external href. Fix: Remove those parts from the SVG, or upload a PNG or JPEG.
400 upload_invalid The upload could not be read as a multipart form. When: A body that is not a valid multipart form, or whose file cannot be parsed. Fix: Send a well-formed multipart/form-data request.
400 upload_no_file The multipart request has no file part. When: An upload request without a file field. Fix: Send the file as multipart/form-data in the field the operation names.

Every call can also return unauthorized (401), rate_limit_exceeded (429) or internal_error (500 / 502). See Responses and errors.