Alternate Futures
GraphQL API

Input types

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.

EnvVarInput

FieldTypeDescription
keyString!
valueString!
secretBoolean

Functions

CreateServiceInput

Generic input for creating a Service registry entry. Used for template-based services and raw compute services that don't need a specialized AFFunction or Site record.

FieldTypeDescription
nameString!
projectIdID!
typeServiceType · ServiceType
templateIdString
flavorStringCatalog flow discriminator. One of 'docker' | 'server' | 'function' | 'template' | 'github' | 'swarm'. Validated server-side; rejected if any other value. Immutable post-creation. 'swarm' defaults type to VM.
dockerImageString
containerPortInt

UpdateServiceInput

Patch a Service registry entry's source-of-truth fields. Used by the Source tab in the web app to let users set/update the Docker image reference and container port for VM/raw services after creation.

Changes apply on the next deploy. The mutation rejects updates while a deployment is in flight (CREATING/WAITING_BIDS/SELECTING_BID/ CREATING_LEASE/SENDING_MANIFEST/DEPLOYING) so the in-progress lease isn't operating against stale fields. ACTIVE deployments are fine to update against: the user must redeploy to pick the new values up.

FieldTypeDescription
dockerImageString
containerPortInt
nameStringRename the service. Display name only: the slug, the internal hostname and every public URL keep the original slug. 1 to 63 characters. A swarm service's name is also its team id: lowercase letters, digits and hyphens (SWARM_NAME_INVALID), unique among the project's swarms (SWARM_NAME_TAKEN) and fixed once a definition version, claim or binding exists (SWARM_NAME_FROZEN).
volumesJSONPersistent volumes for raw Docker images. Pass an empty array to clear all volumes; pass null to leave unchanged. Each volume requires "name" (lowercase letters/digits/hyphen, max 31 chars), "mountPath" (absolute, no trailing slash), and "size" (e.g. "5Gi", "100Mi"). Max 4 per service. Templates ignore this field.
healthProbeJSONOptional application HTTP health probe. Pass null to remove the probe; pass an object to set/replace it. Required key: path (must start with "/"). Optional keys: port (1-65535), expectStatus (HTTP code, default 200), intervalSec (default 30, clamped 10-3600), timeoutSec (default 5, clamped 1-30).
failoverPolicyJSONOptional health-aware auto-failover policy. Pass null to remove the policy; pass an object to set/replace it. Required key: enabled (boolean). Optional keys: maxAttempts (default 3, clamped 1-10), windowHours (default 24, clamped 1-720). Refused on services with persistent volumes: that combination would silently lose data on a failover event.

Domain registration / purchase

LoginWithPersonalAccessTokenDataInput

Input for exchanging a Personal Access Token for an access token

FieldTypeDescription
personalAccessTokenString!
projectIdID

Attestation registry (org-owned allowlist + verified identities)

AddAttestationMeasurementInput

FieldTypeDescription
measurementString!Hex sha256 of the blessed build's app-compose.json.
labelString!

RegisterAttestedIdentityInput

FieldTypeDescription
pubkeyString!Hex Ed25519 public key from the server's GET /identity.
quoteString!Raw TDX quote (hex) binding the pubkey (report_data = sha256(pubkey)).
appIdStringOptional the confidential compute (TEE) tier CVM app id, used to link the identity to an AF service.

Feedback & bug reports

SubmitFeedbackInput

FieldTypeDescription
titleString!
categoryFeedbackCategory! · FeedbackCategory
locationString
descriptionString!

Agent chat system

CreateAgentInput

FieldTypeDescription
nameString!
slugString!
descriptionString
systemPromptString
modelString
functionIdID

CreateChatInput

FieldTypeDescription
agentIdID!
titleString

SendMessageInput

FieldTypeDescription
chatIdID!
contentString!

Observability / APM

TraceQueryInput

FieldTypeDescription
projectIdID!
startTimeDate!
endTimeDate!
serviceNameString
spanNameString
minDurationMsFloat
maxDurationMsFloat
statusCodeString
traceIdString
limitInt
offsetInt

MetricQueryInput

FieldTypeDescription
projectIdID!
startTimeDate!
endTimeDate!
metricNameString
aggregationMetricAggregation · MetricAggregation
intervalString
limitInt

LogQueryInput

FieldTypeDescription
projectIdID!
startTimeDate!
endTimeDate!
severityTextString
minSeverityNumberInt
searchString
traceIdString
limitInt
offsetInt

UpdateObservabilitySettingsInput

FieldTypeDescription
tracesEnabledBoolean
metricsEnabledBoolean
logsEnabledBoolean
traceRetentionInt
metricRetentionInt
logRetentionInt
sampleRateFloat
maxBytesPerHourString

Deployment policy (budget, GPU, runtime constraints)

DeploymentPolicyInput

FieldTypeDescription
acceptableGpuModels[String!]
gpuUnitsInt
gpuVendorString
maxBudgetUsdFloat
maxMonthlyUsdFloat
runtimeMinutesInt

Templates

EnvOverrideInput

FieldTypeDescription
keyString!
valueString!

GpuOverrideInput

FieldTypeDescription
unitsInt!
vendorString!
modelString

ResourceOverrideInput

FieldTypeDescription
cpuFloat
memoryString
storageString
gpuGpuOverrideInput · GpuOverrideInput

DeployFromTemplateInput

FieldTypeDescription
templateIdString!
projectIdID!
serviceNameString
envOverrides[EnvOverrideInput!] · EnvOverrideInput
resourceOverridesResourceOverrideInput · ResourceOverrideInput
policyDeploymentPolicyInput · DeploymentPolicyInput

ComponentTargetInput

FieldTypeDescription
componentIdString!
providerString!
resourceOverridesResourceOverrideInput · ResourceOverrideInput

DeployCompositeTemplateInput

FieldTypeDescription
templateIdString!
projectIdID!
primaryServiceIdIDExisting workspace service to reuse as the primary composite service.
modeString!'fullstack': all components in one lease/provider. 'custom': each component targeted individually via componentTargets.
providerStringProvider for fullstack mode ('the standard compute tier' or 'the confidential compute (TEE) tier'). Ignored in custom mode.
componentTargets[ComponentTargetInput!] · ComponentTargetInputPer-component provider assignments for custom mode.
enabledComponentIds[String!]Which components to deploy (omit to deploy all). Required components are validated.
componentFallbackOverridesJSONOverride fallback values for disabled components (JSON: { componentId: { field: value } }).
serviceNameString
envOverrides[EnvOverrideInput!] · EnvOverrideInput
resourceOverridesResourceOverrideInput · ResourceOverrideInput
policyDeploymentPolicyInput · DeploymentPolicyInput

DecideSwarmRuntimeApprovalInput

FieldTypeDescription
approvalIdID!
idempotencyKeyString!
actionSwarmRuntimeApprovalAction! · SwarmRuntimeApprovalAction
inputJSON
responseString

SubmitSwarmRuntimeRunInput

FieldTypeDescription
projectIdID!
serviceIdID!
agentString!
kindString!
inputJSON!
idempotencyKeyString!
timeoutMsInt!
executionPlanJSON

ConnectSwarmDiscordInput

FieldTypeDescription
projectIdID!
swarmIdString!
channelIdString!Numeric channel id (Developer Mode: Copy Channel ID).
agentStringAgent id from the newest registered definition; omit for the whole swarm.
tokenStringBot token; required when none is stored for the swarm, otherwise replaces it. Never echoed.

BindSwarmDeploymentInput

FieldTypeDescription
projectIdID!
swarmIdString!
serviceIdID!
providerString!
deploymentIdID!
definitionVersionIdID!
runtimeImageDigestString!
idempotencyKeyString!

DeploySwarmRuntimeInput

FieldTypeDescription
projectIdID!
swarmIdString!
serviceIdID!
definitionVersionIdID!
bundleSha256String!
runtimeImageDigestString!
idempotencyKeyString!

RegisterSwarmDefinitionInput

FieldTypeDescription
projectIdID!
swarmIdString!
bundleJSON!
idempotencyKeyString!
parentVersionIdIDOptimistic-concurrency guard (acc swarms push/deploy, 2026-09-18): the version the client last pulled. Refused with SWARM_DEFINITION_STALE when it is no longer the swarm's newest version.

SwarmAgentSpecInput

One agent of a swarm spec (E-MVP M2). name: the agent id and @mention (lowercase letters, digits, - or _, 1 to 64). job: one sentence, 3 to 400 characters; it becomes the persona ("You are <name>. <job>." plus the house rule), exactly as acc add agent writes it. persona (2026-09-26): the whole persona instead, written byte for byte like acc swarms push ships it (1 byte to 64 KiB, printable). Give job or persona, not both. model: an id from swarmModels.

FieldTypeDescription
nameString!
jobString
personaString
modelString!

SwarmEdgeSpecInput

FieldTypeDescription
fromString!
toString!

SwarmSpecInput

What the wizard authors. shape: sequential | parallel | loop | supervisor | handoff | graph. agents are the members in order. parallel needs reducer (one of the agents; the others are the members), supervisor needs supervisor (likewise), loop takes exactly one agent and maxIterations (1 to 100, default 5), handoff exactly two agents, graph needs edges over every agent (acyclic). Anything else is refused with SWARM_SPEC_INVALID.

FieldTypeDescription
shapeString!
agents[SwarmAgentSpecInput!]! · SwarmAgentSpecInput
reducerString
supervisorString
maxIterationsInt
edges[SwarmEdgeSpecInput!] · SwarmEdgeSpecInput

RegisterSwarmDefinitionFromSpecInput

Server-side compile (E-MVP M2): the platform renders the same project files acc would write, compiles them with the signed swarm-local in a cluster Job and registers the bundle like registerSwarmDefinition. Waits waitSeconds (0 to 60, default 30) for the result; still running afterwards => SWARM_COMPILE_PENDING (extensions.compileId): call again with the SAME idempotencyKey to attach, a finished compile replays its version. Failures: SWARM_SPEC_INVALID, SWARM_MODEL_UNSUPPORTED, SWARM_COMPILE_UNAVAILABLE (not configured or the Job could not start), SWARM_COMPILE_FAILED (compiler refused the sources), SWARM_DEFINITION_STALE, CONFLICT.

FieldTypeDescription
projectIdID!
swarmIdString!
specSwarmSpecInput! · SwarmSpecInput
idempotencyKeyString!
parentVersionIdID
waitSecondsInt

IssueSwarmDefinitionBootstrapInput

FieldTypeDescription
projectIdID!
serviceIdID!
providerString!
deploymentIdID!
definitionVersionIdID!
bundleSha256String!
runtimeImageDigestString!
expiresInSecondsInt!
maxUsesInt!
revokeExistingBoolean!
idempotencyKeyString!

RuntimeMcpServerInput

FieldTypeDescription
nameString!
urlString!
bearerTokenFileString!
capabilities[String!]!

BeginIdentityImportInput

FieldTypeDescription
projectIdID!
didString!
subjectTypeIdentitySubjectType! · IdentitySubjectType

CompleteIdentityImportInput

FieldTypeDescription
projectIdID!
challengeIdID!
challengeJSON!
didDocumentJSON!
verificationMethodString!
signatureString!

RotateIdentityInput

FieldTypeDescription
projectIdID!
didString!
didDocumentJSON!
expectedRevisionInt!
verificationMethodString!
signatureString!

DeactivateIdentityInput

FieldTypeDescription
projectIdID!
didString!
verificationMethodString!
signatureString!

IssueIdentityCardInput

FieldTypeDescription
projectIdID!
subjectDidString!
issuerDidString!
statusUrlString!
expiresInSecondsInt!
proofInitiationUriString

RevokeIdentityCredentialInput

FieldTypeDescription
projectIdID!
credentialIdID!
reasonString!

IdentityPublicationConsentInput

FieldTypeDescription
fields[String!]!
correlationReviewedBoolean!
consentedAtDate!
retentionUntilDate!

PublishIdentityCardInput

FieldTypeDescription
projectIdID!
credentialIdID!
domainString!
consentIdentityPublicationConsentInput · IdentityPublicationConsentInput

CreateIdentityProofRequestInput

FieldTypeDescription
projectIdID!
providerString!
purposeString!
policySha256String!
audienceString!
responseUriString!
subjectDidString

RegisterA2aAgentCardInput

FieldTypeDescription
projectIdID!
agentKeyString!
cardJSON!
serviceIdID
deploymentIdID

IssueA2aAccessTokenInput

FieldTypeDescription
projectIdID!
agentKeyString!
credentialIdID!
invocationJSON!
expiresInSecondsInt!

IssueIdentityDelegationInput

FieldTypeDescription
projectIdID!
issuerDidString!
controllerDidString!
agentDidString!
tenantString!
resourceString!
actions[String!]!
audienceString!
expiresInSecondsInt!
statusUrlString!
maxChainDepthInt!
redelegationBoolean!
parentSha256String

Mutations

CreateProjectDataInput

FieldTypeDescription
nameString!

UpdateProjectDataInput

FieldTypeDescription
nameString

Github deploy (phase: github deploy, 2026-04-20)

CreateGithubServiceEnvVarInput

FieldTypeDescription
keyString!
valueString!
secretBoolean

CreateGithubServiceInput

FieldTypeDescription
projectIdID!
idempotencyKeyStringSHA-256 request digest used to make create/dispatch retries idempotent.
installationIdID!Local id of the GithubInstallation row (NOT the GitHub-side installation_id).
ownerString!
repoString!
branchStringDefaults to the repo's default branch when omitted.
rootDirectoryStringMonorepo subdir (defaults to '.').
buildCommandString
startCommandString
nameStringDisplay name; defaults to repo name.
envVars[CreateGithubServiceEnvVarInput!] · CreateGithubServiceEnvVarInput

ConnectGithubRepoInput

Connect an existing (empty, github-flavor) Service to a GitHub repo. Used by the in-panel Source-tab picker: the Service row is created first by the catalog flow (createService), then connected here. This kicks off the first BuildJob and spawns the K8s builder. The compute provider is NOT chosen here: the build callback auto-deploys via the existing Service compute config the same way the Deploy button would.

FieldTypeDescription
serviceIdID!
installationIdID!
ownerString!
repoString!
branchString
rootDirectoryString
buildCommandString
startCommandString

On this page