Alternate Futures
API (GraphQL)

Mutations

Generated from the API server source (@alternatefutures/backend 0.1.2) on every merge. Endpoint https://api.alternatefutures.ai/graphql, header Authorization: Bearer <personal access token>. See the GraphQL API overview for how to call it. Left out on purpose: provider-specific types, fields and arguments; operations of the retired hosting product (sites, IPFS storage, functions) and admin-only operations.

Auth - SDK token exchange

loginWithPersonalAccessToken

Exchange a Personal Access Token for a short-lived access token. Used by the SDK to authenticate subsequent requests.

ArgumentTypeDescription
dataLoginWithPersonalAccessTokenDataInput! · LoginWithPersonalAccessTokenDataInput

Returns String!.

Auth

createPersonalAccessToken

ArgumentTypeDescription
nameString!
expiresAtDate

Returns PersonalAccessTokenCreated! · PersonalAccessTokenCreated.

deletePersonalAccessToken

ArgumentTypeDescription
idID!

Returns Boolean!.

Projects

createProject

ArgumentTypeDescription
dataCreateProjectDataInput! · CreateProjectDataInput

Returns Project! · Project.

updateProject

ArgumentTypeDescription
idID!
dataUpdateProjectDataInput! · UpdateProjectDataInput

Returns Project! · Project.

deleteProject

ArgumentTypeDescription
idID!

Returns Boolean!.

projectChatSession

Mint a single-use join ticket (plus room id, relay URL and room secret) for a project's chat. Requires project access; organization projects only. Relay-blind, not end-to-end: the platform can read project chat.

ArgumentTypeDescription
projectIdID!

Returns ProjectChatSession! · ProjectChatSession.

publicChatTicket

Mint a single-use join ticket for the hosted public chat. Requires only an authenticated caller: no org or project check. The ticket is NOT bound to a room: the platform never learns which public rooms exist or who is in them, only that this user opened chat.

Returns PublicChatTicket! · PublicChatTicket.

Services

createService

ArgumentTypeDescription
inputCreateServiceInput! · CreateServiceInput

Returns Service! · Service.

updateService

ArgumentTypeDescription
serviceIdID!
inputUpdateServiceInput! · UpdateServiceInput

Returns Service! · Service.

updateServicePriority

ArgumentTypeDescription
serviceIdID!
shutdownPriorityInt!

Returns Service! · Service.

deleteService

ArgumentTypeDescription
idID!

Returns Service! · Service.

Attestation registry (org allowlist; AF hosts, org authors)

addAttestationMeasurement

Bless a build measurement (compose_hash) in the active org's allowlist.

ArgumentTypeDescription
inputAddAttestationMeasurementInput! · AddAttestationMeasurementInput

Returns AttestationMeasurement! · AttestationMeasurement.

revokeAttestationMeasurement

Revoke a blessed measurement. Idempotent; revocation retires every identity minted from it.

ArgumentTypeDescription
idID!

Returns AttestationMeasurement! · AttestationMeasurement.

registerAttestedIdentity

Verify a server's quote (Intel DCAP roots, in-process) and record its identity. Requires the quote's measurement to be ACTIVE in the active org's allowlist and the quote's report_data to bind the pubkey.

ArgumentTypeDescription
inputRegisterAttestedIdentityInput! · RegisterAttestedIdentityInput

Returns AttestedIdentity! · AttestedIdentity.

Agent chat

createAgent

ArgumentTypeDescription
inputCreateAgentInput! · CreateAgentInput

Returns Agent! · Agent.

createChat

ArgumentTypeDescription
inputCreateChatInput! · CreateChatInput

Returns Chat! · Chat.

sendMessage

ArgumentTypeDescription
inputSendMessageInput! · SendMessageInput

Returns Message! · Message.

deleteChat

ArgumentTypeDescription
idID!

Returns Boolean!.

Observability settings

updateObservabilitySettings

ArgumentTypeDescription
projectIdID!
inputUpdateObservabilitySettingsInput! · UpdateObservabilitySettingsInput

Returns ObservabilitySettings! · ObservabilitySettings.

Templates

deployFromTemplate

ArgumentTypeDescription
inputDeployFromTemplateInput! · DeployFromTemplateInput

Returns a deployment object for the service's compute tier (provider-specific, not documented here). †

deployCompositeTemplate

ArgumentTypeDescription
inputDeployCompositeTemplateInput! · DeployCompositeTemplateInput

Returns CompositeDeploymentResult! · CompositeDeploymentResult.

Service environment variables

setServiceEnvVar

ArgumentTypeDescription
serviceIdID!
keyString!
valueString!
secretBoolean

Returns ServiceEnvVar! · ServiceEnvVar.

deleteServiceEnvVar

ArgumentTypeDescription
serviceIdID!
keyString!

Returns Boolean!.

bulkSetServiceEnvVars

ArgumentTypeDescription
serviceIdID!
vars[EnvVarInput!]! · EnvVarInput

Returns [ServiceEnvVar!]! · ServiceEnvVar.

revealServiceEnvVar

ArgumentTypeDescription
serviceIdID!
keyString!

Returns String!.

Service port configuration

setServicePort

ArgumentTypeDescription
serviceIdID!
containerPortInt!
publicPortInt
protocolString

Returns ServicePort! · ServicePort.

deleteServicePort

ArgumentTypeDescription
serviceIdID!
containerPortInt!

Returns Boolean!.

Service linking

linkServices

ArgumentTypeDescription
sourceServiceIdID!
targetServiceIdID!
aliasString

Returns ServiceLink! · ServiceLink.

unlinkServices

ArgumentTypeDescription
sourceServiceIdID!
targetServiceIdID!

Returns Boolean!.

Deployment file access (files tab)

writeServiceFile

ArgumentTypeDescription
serviceIdID!
pathString!
contentString!

Returns ServiceFileWriteResult! · ServiceFileWriteResult.

createServiceDirectory

ArgumentTypeDescription
serviceIdID!
pathString!

Returns Boolean!.

renameServiceFile

ArgumentTypeDescription
serviceIdID!
fromPathString!
toPathString!

Returns Boolean!.

deleteServiceFile

ArgumentTypeDescription
serviceIdID!
pathString!

Returns Boolean!.

Feedback

submitFeedback

ArgumentTypeDescription
inputSubmitFeedbackInput! · SubmitFeedbackInput

Returns FeedbackReport! · FeedbackReport.

GitHub deploy

beginGithubInstallationClaim

Begin a one-use GitHub user-authorization proof bound to the caller, AF organization, and exact installation id returned by GitHub's setup URL.

ArgumentTypeDescription
installationIdString!
orgIdID

Returns GithubInstallationClaim! · GithubInstallationClaim.

syncGithubInstallation

Create or grant an installation only after exchanging a GitHub user OAuth code and proving that user can access the exact App installation.

ArgumentTypeDescription
stateString!
codeString!

Returns GithubInstallationSyncResult! · GithubInstallationSyncResult.

refreshGithubInstallations

Live-pull all accessible App installations from GitHub into the local DB and return them. Slow path: UI uses this only on explicit Refresh / post-install.

ArgumentTypeDescription
orgIdID

Returns [GithubInstallation!]! · GithubInstallation.

uninstallGithubInstallation

Remove only this AF organization's installation grant and detach its services. GitHub-wide uninstall remains an installation-admin action on github.com and is reconciled by the signed deletion webhook.

ArgumentTypeDescription
installationIdID!
orgIdID

Returns Boolean!.

createGithubService

ArgumentTypeDescription
inputCreateGithubServiceInput! · CreateGithubServiceInput

Returns Service! · Service.

connectGithubRepo

ArgumentTypeDescription
inputConnectGithubRepoInput! · ConnectGithubRepoInput

Returns Service! · Service.

redeployGithubService

Trigger a new build. With no sha, builds the tip of the tracked branch (default behaviour, used by top-level Rebuild). With a sha (7-40 char hex commit SHA), rebuilds that exact commit: used by the per-row rebuild button in build history.

ArgumentTypeDescription
serviceIdID!
shaString

Returns BuildJob! · BuildJob.

† Some fields, arguments or return types are omitted from this page: provider-specific ones, or ones that belong to retired or admin-only surfaces.

On this page