uidudevelopers
Reference

@uidu/client reference

Every export of @uidu/client, grouped by domain — 154 functions, generated from the source.

Every function takes a UiduClient as its first argument. Kind: read runs a query, write runs a mutation and returns its payload (check errors), helper is pure. Auth: public token works in the browser; Bearer needs an account token (apiKey) and must run server-side — see Writes. CLI lists the uidu commands that call the function.

Domains: Client & utilities · CMS — Sites · CMS — Projects (legacy) · Stories · Help center · Knowledge base · Search · Forms · Events · Donations · Courses · Calls · Jobs & applications · Contacts & deals · Campaigns · People (HR) · Goals (OKRs) · Spaces, tasks & notes · Bookings & calendars · Models (custom data) · Provisioning & actions

Client & utilities

Client construction, errors, pagination, field-value helpers.

Guide: Client & utilities.

  • UiduClient — Sends GraphQL documents to one uidu endpoint with the configured credentials, and throws a UiduError when a request fails.
  • UiduError — What UiduClient throws: code is GRAPHQL_ERROR (with graphQLErrors), NETWORK_ERROR, TOKEN_ERROR or CONFIG_ERROR.
FunctionKindAuthCLIDescription
createClienthelper——Build a UiduClient; it needs a workspace or an endpoint, and authenticates with publicToken, apiKey or getToken.
fromBridgehelper——Client config for a custom app, from a connected @uidu/app-bridge: the bridge's GraphQL endpoint, with its session token asked for per request.
normalizeFieldValueContenthelper——Wrap a content payload in { value } unless it already carries a value key. Returns the input untouched when there is nothing to do.
normalizeFieldValuesAttributeshelper——Normalize a standalone fieldValuesAttributes array. Exported for callers that assemble one by hand outside an SDK mutation.
paginateread——Walks every page of a Relay-style connection and returns a flat array of nodes.

Types: PaginateOptions, UiduClientConfig, UiduErrorOptions

CMS — Sites

The new CMS: Site → page/block Models → ModelItems.

Guide: CMS — Sites.

FunctionKindAuthCLIDescription
createSitewriteBearersites createProvisions a new Site in the workspace/account (tenantId). Bearer token (apiKey) — this is workspace admin territory, never a public write. Returns the mutation payload as-is, including errors.
getPageBySlugreadpublic token—A page of the Site by slug, with its field values and its ordered blocks. Only published pages unless includeDrafts.
getSingletonBlockreadpublic token—A singleton of the Site — the header, the footer, the nav — by its Model's shortname, with its field values and blocks.
getSitereadpublic token—A Site by its id — for previews, where there is no domain to go by.
getSiteByDomainreadpublic token—The Site served on domain (e.g. www.acme.org), or null.
listSitePagesreadpublic token—The Site's pages, for navigation and sitemaps: published only unless includeDrafts, singletons (header, footer) left out.

Types: Site, SiteBlock, SiteFields, SiteModel, SitePage, SitePageSummary

CMS — Projects (legacy)

Legacy CMS: Project → Page → PageBlock → FieldValue.

Guide: CMS — Projects (legacy).

FunctionKindAuthCLIDescription
createFieldValuewriteBearerfield createCreate a field value, e.g. set a page block's field (fieldId, content). Returns the payload (with errors) or null; the new value is at fieldValue.node.
createPagewriteBearerpage createCreate a legacy CMS page from a templateId, with slug and optional metadataAttributes (there is no projectId attribute). Returns the payload (with errors) or null.
createPageBlockwriteBearerblock createPlace a template block on a page (pageId, templateBlockId, both numeric). Returns the payload (with errors) or null.
createProjectwriteBearerproject createCreate a legacy CMS project (name, slug, domain). Returns the payload (with errors) or null; the new project is at project.node.
getPagereadpublic tokenpage getA legacy CMS page by project and slug, with its metadata and ordered pageBlocks (and any linked form's questions), or null.
getTemplatereadpublic token—A legacy CMS template by id, with every page it holds and their blocks, or null.
listPagesreadpublic tokenpages listThe pages of a legacy CMS project (id and slug), one Relay page at a time; use paginate with ListPagesDocument for all of them.
listProjectsreadpublic tokenprojects listThe workspace's CMS projects. A page lives in one, and getPage needs its id.

Types: Page, Template

Documents (for paginate): ListPagesDocument

Stories

Blog posts / news.

Guide: Stories.

FunctionKindAuthCLIDescription
createStorywriteBearerstories createCreate a story; returns the payload as-is, { errors, story }, validation failures included.
getStoryreadpublic tokenstories getOne story with its rich-text body, or null.
listStoriesreadpublic tokenstories listThe workspace's stories as a flat array of summaries (no body); page with first/after.
updateStorywriteBearerstories updateUpdate a story: { input: { id, attributes } } (create it with createStory). Returns the payload (with errors) or null.

Types: Story

Documents (for paginate): ListStoriesDocument

Help center

Help-center channels.

Guide: Help center.

FunctionKindAuthCLIDescription
createChannelwriteBearerchannel createCreate a help-center channel. Returns the payload (with errors) or null. The new channel is at channel.node.
deleteChannelwriteBearerchannel deleteDelete a help-center channel by { input: { id } }. Returns the payload (with errors) or null.
getChannelreadpublic tokenchannel getOne help center channel with its collections and their articles in a single request (the last 100 of each), or null.
listChannelsreadpublic tokenchannel listThe workspace's help center channels. isDefault marks the one the workspace treats as its main channel — a caller that has no channel id configured should prefer it over the first row.
updateChannelwriteBearerchannel updateUpdate a help-center channel: { input: { id, attributes } }. Returns the payload (with errors) or null.

Types: Channel

Knowledge base

KB collections and articles.

Guide: Knowledge base.

FunctionKindAuthCLIDescription
createKbArticlewriteBearerkb-articles createCreate a knowledge-base article in attributes.kbCollectionId. Returns the payload (with errors) or null. The new article is at kbArticle.node.
createKbCollectionwriteBearerkb-collections createCreate a knowledge-base collection. Returns the payload (with errors) or null. The new collection is at kbCollection.node.
deleteKbArticlewriteBearerkb-articles deleteDelete a knowledge-base article by { input: { id } }. Returns the payload (with errors) or null.
deleteKbCollectionwriteBearerkb-collections deleteDelete a knowledge-base collection by { input: { id } }. Returns the payload (with errors) or null.
getKbArticlereadpublic tokenkb-articles getOne knowledge-base article with its rich-text body and its collection, or null.
getKbCollectionreadpublic tokenkb-collections getOne knowledge-base collection with its first 50 articles, or null.
listKbArticlesreadpublic tokenkb-articles listKnowledge-base articles across every collection, as a flat array; page with first/after (or last/before).
listKbCollectionsreadpublic tokenkb-collections listThe workspace's knowledge-base collections as a flat array; page with first/after (or last/before).
updateKbArticlewriteBearerkb-articles updateUpdate a knowledge-base article: { input: { id, attributes } }. Returns the payload (with errors) or null.
updateKbCollectionwriteBearerkb-collections updateUpdate a knowledge-base collection: { input: { id, attributes } }. Returns the payload (with errors) or null.

Types: KbArticle, KbCollection

Documents (for paginate): ListKbArticlesDocument, ListKbCollectionsDocument

Workspace-wide full-text search.

Guide: Search.

FunctionKindAuthCLIDescription
searchreadpublic token—Search the workspace index, optionally limited to models, with filters and sorting in params; page with first/after.

Types: SearchResult

Forms

Forms, their questions, and visitor responses.

Guide: Forms.

FunctionKindAuthCLIDescription
createFormwriteBearerforms createCreate a form, questions included via attributes.formQuestionsAttributes. Returns the payload (with errors) or null. The new form is at form.node.
createFormResponsewriteBearer—Submit a new response to a form; returns the payload as-is, { errors, formResponse }, validation failures included.
deleteFormwriteBearerforms deleteDelete a form by { input: { id } }. Returns the payload (with errors) or null.
getFormreadpublic tokenforms getOne form with its questions (inputs, a connection of FormQuestion nodes with field metadata) ready to render, or null.
listFormsreadpublic tokenforms listThe workspace's forms as a flat array of summaries, without their questions (use getForm for those); page with first/after.
updateFormwriteBearerforms updateUpdate a form: { input: { id, attributes } }. Returns the payload (with errors) or null.
updateFormResponsewriteBearer—Update a form response (answers by field value id, or a state event like 'complete!'); returns { errors, formResponse } as-is.

Types: Form

Documents (for paginate): ListFormsDocument

Events

Events, their instances, and attendances (RSVPs).

Guide: Events.

FunctionKindAuthCLIDescription
createAttendancewriteBearerattendances createRSVP a contact to an event: attendableId is an event instance id, never the event id.
createEventwriteBearerevents createCreate an event; returns the payload as-is, { errors, event }, validation failures included.
getEventreadpublic tokenevents getOne event with its primary address, its next or current instance and all its instances, or null.
listEventsreadpublic tokenevents listThe workspace's events as a flat array of summaries, each with its next or current instance; page with first/after.
updateEventwriteBearerevents updateUpdate an event: { input: { id, attributes } } (create it with createEvent). Returns the payload (with errors) or null.

Types: Event

Documents (for paginate): ListEventsDocument

Donations

Donation campaigns and donations.

Guide: Donations.

FunctionKindAuthCLIDescription
createDonationwriteBearer—Record a donation (amount in cents) to a campaign, creating the donor's contact inline; returns { errors, donation } as-is.
createDonationCampaignwriteBearerdonations createCreate a donation campaign (goal in cents); returns the payload as-is, { errors, donationCampaign }.
deleteDonationCampaignwriteBearerdonations deleteDelete a donation campaign by { input: { id } }. Returns the payload (with errors) or null.
getDonationCampaignreadpublic tokendonations getOne donation campaign with its body, its totals (goal, donationsAmount, in cents) and its donor form, or null.
listDonationCampaignsreadpublic tokendonations listThe workspace's donation campaigns as a flat array of summaries with their totals in cents; page with first/after.
updateDonationCampaignwriteBearerdonations updateUpdate a donation campaign: { input: { id, attributes } }. Returns the payload (with errors) or null.

Types: DonationCampaign

Documents (for paginate): ListDonationCampaignsDocument

Courses

Courses, lectures and enrollments.

Guide: Courses.

FunctionKindAuthCLIDescription
createCoursewriteBearercourses createCreate a course from { input: { attributes } }. Returns the payload (with errors) or null.
deleteCoursewriteBearercourses deleteDelete a course by { input: { id } }. Returns the payload (with errors) or null.
getCoursereadpublic tokencourses getOne course with its rich-text body, or null.
getEnrollmentreadBearer—One enrollment with its course, contact and custom fields (fieldValuesByShortname), or null.
getLecturereadpublic token—One lecture with its body, its course and its nextLecture / previousLecture for navigation, or null.
listCoursesreadpublic tokencourses listThe workspace's courses as a flat array, optionally filtered with search params; page with first/after.
listEnrollmentsreadBearer—Course enrollments as a flat array, optionally filtered with search params; page with first/after.
listLecturesreadpublic token—Lectures across every course as a flat array (filter by course.id yourself), with scopes, orderBy, from/to; page with first/after.
updateCoursewriteBearercourses updateUpdate a course: { input: { id, attributes } }. Returns the payload (with errors) or null.

Types: Course, Enrollment, Lecture

Documents (for paginate): ListCoursesDocument, ListEnrollmentsDocument, ListLecturesDocument

Calls

Open calls (grants, applications windows).

Guide: Calls.

FunctionKindAuthCLIDescription
getCallreadpublic tokencalls getOne call (a job opening or open call) with its application form, same shape as getForm, or null.
listCallsreadpublic tokencalls listThe workspace's calls as a flat array of summaries, without their forms; page with first/after.

Types: Call

Documents (for paginate): ListCallsDocument

Jobs & applications

Job postings (calls of kind job) and the applications to them.

Guide: Jobs & applications.

FunctionKindAuthCLIDescription
completeApplicationwriteBearer—Submit a draft application, the last step of applying.
createApplicationwriteBearerapplications createSubmit an application to a job. Pass attributes.applicableId (the job's id) plus contactAttributes and/or formResponseAttributes. Returns the mutation payload as-is (including any errors) rather than throwing.
getJobreadpublic tokenjobs getFetch a single job posting; returns null if the call is not a job.
listApplicationsreadBearerapplications listList applications across the workspace (requires a Bearer token).
listJobsreadpublic tokenjobs listList job postings (calls of kind job).
updateApplicationwriteBearer—Update an application, optionally firing a state event (event: 'complete!'). Returns the mutation payload as-is (including any errors) rather than throwing.

Types: Application, Job

Documents (for paginate): ListApplicationsDocument

Contacts & deals

CRM contacts, organisations and deals.

Guide: Contacts & deals.

FunctionKindAuthCLIDescription
createContactwriteBearercontacts createCreate a CRM contact from { input: { attributes } }. Returns the payload (with errors) or null.
createDealwriteBearerdeals createCreate a deal in a pipeline (attributes.pipelineId, statusId). Returns the payload (with errors) or null. The new deal is at deal.node.
deleteContactwriteBearercontacts deleteDelete a contact by { input: { id } }. Returns the payload (with errors) or null.
getContactreadBearercontacts getOne contact with its address and custom fields (fieldValuesByShortname), or null; a public token sees none.
getDealreadBearerdeals getOne deal with its pipeline, status and owner (user), or null; amount is in cents.
listContactsreadBearercontacts listEvery contact the client may see, as an array: the field is not a connection, so there is no pagination.
listDealsreadBearerdeals listThe workspace's deals as a flat array, optionally filtered with search params; page with first/after.
updateDealwriteBearerdeals updateUpdate a deal, e.g. move it to another statusId: { input: { id, attributes } }. Returns the payload (with errors) or null.

Types: Contact, Deal

Documents (for paginate): ListDealsDocument

Campaigns

Marketing and email campaigns.

Guide: Campaigns.

FunctionKindAuthCLIDescription
getCampaignreadBearercampaigns getOne campaign with its preferences and target list, or null; a public token sees none.
listCampaignsreadBearercampaigns listThe workspace's campaigns as a flat array, optionally filtered by kind and status; page with first/after.
listEmailCampaignsreadBearer—The email blasts of the workspace's campaigns with their delivery metrics (sent, opened, clicked), as a flat array; page with first/after.

Types: Campaign

Documents (for paginate): ListCampaignsDocument, ListEmailCampaignsDocument

People (HR)

Employees, employments (contracts), compensations, time clocks, benefits and HR reference data.

Guide: People (HR).

FunctionKindAuthCLIDescription
contractEventshelper——Flatten employment history into dated contract events, most recent first: - the employee's earliest contract is a hire (assunzione) on its start date; - every later contract is a variation (variazione) on its start date; - any contract with an end date yields a termination (cessazione) on it.
createBenefitwriteBearerbenefits createCreate a benefit in the workspace's catalog (name, category, provider, employer/employee costs). Returns the payload (with errors) or null; it is at benefit.node.
createBenefitEnrollmentwriteBearerbenefit-enrollments createEnroll an employment in a benefit (benefitId, employmentId, enrolledAt). Returns the payload (with errors) or null; it is at benefitEnrollment.node.
createCcnlwriteBearerccnls createCreate a CCNL (national collective labor contract) — the first-class Ccnl record (code, sector, contract levels), distinct from the Kind-tagged rows listCcnls returns above. Employment.ccnl / ccnlId point at this first-class type. Requires a Bearer token (apiKey).
createCompensationwriteBearercompensations createAdd a pay item to an employment (attributes.employmentId, amount, currency, frequency, effectiveFrom). Returns the payload (with errors) or null. The new item is at compensation.node.
createEmployeewriteBeareremployees createCreate the HR record for a workspace user (attributes.userId). Returns the payload (with errors) or null. The new employee is at employee.node.
createEmploymentwriteBeareremployments createHire: open a new employment (contract) for attributes.employeeId with its start date, kind, role and hours. Returns the payload (with errors) or null. The new employment is at employment.node.
createTimeClockwriteBearertime-clocks createRecord a time-clock punch (beginsAt, optional finishesAt, resourceId). Returns the payload (with errors) or null. The new punch is at timeClock.node.
deleteCompensationwriteBearercompensations deleteDelete a pay item by { input: { id } }. Returns the payload (with errors) or null.
deleteEmploymentwriteBeareremployments deleteDelete an employment by { input: { id } } (to end a contract, use terminateEmployment instead). Returns the payload (with errors) or null.
getEmployeereadBearer—One employee with current employment, today's time clocks and the shifts of the week starting weekStartingAt (see weekStartFor), or null.
listCcnlsreadBearerccnls listList the CCNLs (national collective labor contracts) configured for the workspace — used for an employment's ccnlId.
listCirclesreadBearer—List the workspace circles. Circles come in two flavours distinguished by kind: org units (e.g. departments — used as an employment's circleId) and roles (kind === 'role' — used as an employment's roleId). Use listRoles when you only want the role-Circles.
listEmployeesreadBeareremployees listThe workspace's employees with their current employment, as a flat array; page with first/after.
listEmploymentHistoryreadBearer—List every employee with their full employment (contract) history — not just the current one. Use contractEvents to turn this into a flat, dated list of hires, terminations and contract variations.
listKindsreadBearer—List Kind records for the given polymorphic models.
listOfficesreadBeareroffices listList the workspace offices — used for an employment's employmentOfficesAttributes.
listRolesreadBearerroles listList only the role-Circles (structured job titles) — an employment's roleId.
terminateEmploymentwriteBearer—Terminate (cessazione) an employment by closing it with an end date and reason. Thin semantic wrapper over updateEmployment. endReason is one of: resignation, termination, contract_end, retirement, other, resignation_just_cause, dismissal_just_cause, dismissal_subjective_reason, dismissal_objective_reason, collective_dismissal, mutual_agreement, probation_failed, death, business_closure.
updateCompensationwriteBearercompensations updateUpdate a pay item: { input: { id, attributes } }. Returns the payload (with errors) or null.
updateEmployeewriteBeareremployees updateUpdate an employee's HR record (code, kiosk PIN, time-clock flags): { input: { id, attributes } }. Returns the payload (with errors) or null.
updateEmploymentwriteBeareremployments updateUpdate an employment: { input: { id, attributes } }; to end one, prefer terminateEmployment. Returns the payload (with errors) or null.
weekStartForhelper——Compute the Monday of the week containing date as an ISO8601 date string. Useful for the weekStartingAt argument required by getEmployee (and any other weekly-aggregated employee fields).

Types: Circle, CompensationRecord, ContractEvent, ContractEventType, Employee, EmployeeContracts, EmploymentRecord, Kind, Office

Documents (for paginate): ListEmployeesDocument

Goals (OKRs)

Objectives, key results and timeframes, plus value/progress helpers.

Guide: Goals (OKRs).

FunctionKindAuthCLIDescription
getGoalreadBearergoals getOne goal with its key results (subgoals).
goalProgresshelper——How far the goal is, 0 to 1 (above 1 when it overshoots). goal.progress itself is percent x100: 10000 is done.
goalTimeElapsedhelper——How much of the goal's timeframe has passed, 0 to 1, or null when it has none. A goal whose goalProgress is below this is behind schedule.
goalValuehelper——A stored goal value (initialValue, currentValue, targetValue) in the unit a person typed: uidu keeps every one of them x100. For percentage that is percent points (45 = 45%), for currency whole units of goal.currency, for checkbox 1 or 0. null stays null.
isGoalBehindhelper——Behind schedule: less done than time elapsed, by more than tolerance (0.1 = ten points). false for a goal with no timeframe or one already accomplished. The goal's own status (off_track, needs_attention) is its owner's judgement — show it next to this, don't replace one with the other.
listGoalsreadBearergoals listEvery goal of the workspace (objectives and key results alike), newest first. Without first, all of them.
listTimeframesreadBearertimeframes listThe workspace's timeframes (the periods goals run over, active marks the current ones) as a flat array; page with first/after.
toGoalRawhelper——The inverse of goalValue, for updateGoal.
updateGoalwriteBearergoals updateAuthoring (Bearer / apiKey). Returns the payload, incl. errors. initialValue / currentValue / targetValue are stored x100: pass toGoalRaw(value), never the number a person typed.

Types: Goal, Timeframe

Documents (for paginate): ListGoalsDocument, ListTimeframesDocument

Spaces, tasks & notes

Collaboration primitives: spaces, tasks, notes.

Guide: Spaces, tasks & notes.

FunctionKindAuthCLIDescription
createNotewriteBearernotes createCreate a note. Returns the payload (with errors) or null; the new note is at note.node.
createSpacewriteBearerspaces createCreate a space, the container tasks live in. Returns the payload (with errors) or null; the new space is at space.node.
createTaskwriteBearertasks createCreate a task, usually in a space (attributes.spaceId). Returns the payload (with errors) or null.
deleteNotewriteBearernotes deleteDelete a note by { input: { id } }. Returns the payload (with errors) or null.
deleteSpacewriteBearerspaces deleteDelete a space by { input: { id } }. Returns the payload (with errors) or null.
deleteTaskwriteBearertasks deleteDelete a task by { input: { id } }. Returns the payload (with errors) or null.
updateNotewriteBearernotes updateUpdate a note: { input: { id, attributes } }. Returns the payload (with errors) or null.
updateSpacewriteBearerspaces updateUpdate a space: { input: { id, attributes } }. Returns the payload (with errors) or null.
updateTaskwriteBearertasks updateUpdate a task, e.g. its statusId or dates: { input: { id, attributes } }. Returns the payload (with errors) or null.

Bookings & calendars

Bookings, calendars and calendar events.

Guide: Bookings & calendars.

FunctionKindAuthCLIDescription
getBookingreadBearerbookings getOne booking with its contact, totals in cents and custom fields (fieldValuesByShortname), or null; a public token sees none.
getCalendarreadpublic token—One calendar (name, color, time zone), or null.
getCalendarEventreadpublic token—One calendar event with its rich-text body and its calendar, or null.
listBookingsreadBearerbookings listThe workspace's bookings as a flat array; page with first/after (or last/before); a public token gets an empty list.
listCalendarEventsreadpublic token—Calendar events as a flat array, optionally narrowed by calendarIds and named scopes (e.g. upcoming); page with first/after.
listCalendarsreadpublic token—The workspace's calendars as a flat array; page with first/after (or last/before).

Types: Booking, Calendar, CalendarEvent

Documents (for paginate): ListBookingsDocument, ListCalendarEventsDocument, ListCalendarsDocument

Models (custom data)

Define your own record types (Models, Fields) and store ModelItems.

Guide: Models (custom data).

FunctionKindAuthCLIDescription
createFieldwriteBearer—Pass fieldableId (the model) with fieldableType: 'Model': a custom app may only name a type that matches the record it loads.
createFieldOptionwriteBearer—Add an option to a select-kind field (attributes.fieldId, name, color). Returns the payload (with errors) or null.
createModelwriteBearer—Create a model in a WorkspaceApp (attributes.modelableId, name, namePlural). Returns the payload (with errors) or null.
createModelItemwriteBearer—Pass attributes.modelId and attributes.fieldValuesAttributes — build the latter by shortname with toFieldValuesAttributes.
deleteFieldwriteBearer—Delete a field from its model by { input: { id } }. Returns the payload (with errors) or null.
deleteFieldOptionwriteBearer—Delete a select option by { input: { id } }. Returns the payload (with errors) or null.
deleteFieldValuewriteBearer—Clear a single value by its FieldValue id; deleteLinkedRecord: true also deletes the record it links to. Returns the payload (with errors) or null.
deleteModelItemwriteBearer—Delete an item by { input: { id } }. Returns the payload (with errors) or null.
ensureModelwriteBearer—Find the app's model by name, or create it — and any of fields it lacks. Returns the model with all its fields. What a custom app runs on its first load until schemas come from an install-time manifest (custom apps spec, step 3). Throws a UiduError (MUTATION_ERROR) when a write is refused.
getModelreadBearer—One model with its fields, or null when the id is not a Model.
getModelItemreadBearer—One model item with its values and its model.id, or null when the id is not a ModelItem.
listModelItemsreadBearer—A model's items. Each carries fieldValuesByShortname — { room: 'Aula Magna', when: '…' } — the easiest shape to read values from.
listModelsreadBearer—The models of a WorkspaceApp, with their fields.
toFieldValuesAttributeshelper——{ room: 'Aula Magna' } → [{ fieldId: '<id of room>', content: { value: 'Aula Magna' } }], for createModelItem / updateModelItem. Throws on a shortname the model doesn't have; skips undefined values.
updateFieldwriteBearer—Update a field (name, required, preferences…): { input: { id, attributes } }. Returns the payload (with errors) or null.
updateFieldOptionwriteBearer—Update a select option: { input: { id, attributes } }. Returns the payload (with errors) or null.
updateFieldValuewriteBearer—Set a single value by its FieldValue id: { input: { id, attributes: { content: { value } } } }. Returns the payload (with errors) or null.
updateModelwriteBearer—Rename or reconfigure a model: { input: { id, attributes } }. Returns the payload (with errors) or null.
updateModelItemwriteBearer—Update an item: { input: { id, attributes: { fieldValuesAttributes } } }, built with toFieldValuesAttributes. Returns the payload (with errors) or null.

Types: EnsureModelOptions, Model, ModelField, ModelFieldOption, ModelItem

Provisioning & actions

Create workspaces, rotate API credentials, and run any tool-flagged ActionKey.

Guide: Provisioning & actions.

FunctionKindAuthCLIDescription
createWorkspacewriteBearerworkspace createCreate a workspace owned by the authenticated account (attributes.name, subdomain…). Returns the payload (with errors) or null.
executeActionwriteBearertools callRun any backend action by key (an ActionKey flagged of_kind_tool_key), with optional id and attributes; returns { result, errors } or null.
generateWorkspaceApiCredentialswriteBearerworkspace credentialsRotate + return a workspace's API credentials (apiKey/apiSecret). Operates on the current workspace. Use the returned credentials to wire a scaffolded app.

On this page