Need help with your APIs? I offer API discovery, governance & evangelism services. Explore services →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

The San Francisco Compute Company Orders API

Estimate an order before placing it: filled price, fee, and operational notices.

The San Francisco Compute Company Orders API is one of 14 APIs that The San Francisco Compute Company publishes on the APIs.io network, described by a machine-readable OpenAPI specification.

Tagged areas include Orders. The published artifact set on APIs.io includes an OpenAPI specification, API documentation, an API reference, and authentication docs.

This API exposes 5 operations across 3 paths, and defines 43 schemas. It is described by OpenAPI 3.1.0, at version 0.1.0.

Requests are made against a single base URL, https://api.sfcompute.com.

5 operations 3 paths 43 schemas 1 DELETE2 GET2 POST

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.1.0
API Version
0.1.0
Base URL
https://api.sfcompute.com/preview/v2
Authentication
HTTP Bearer
Resource Areas
1

Authentication & Security 1

The San Francisco Compute Company Orders API declares 1 security scheme for authenticating requests. It accepts HTTP bearer tokens (JWT) (bearer_auth). By default, every request must be authenticated.

  • bearer_auth — Create an API token using sf tokens create or at https://sfcompute.com/account/api-keys.

Paths & Operations 5

Across 3 paths, the API surfaces 5 operations — 1 DELETE, 2 GET, 2 POST. Each is listed below with its method, path, parameters, and response codes.

Orders 5

Estimate an order before placing it: filled price, fee, and operational notices.

POST
/preview/v2/order_preview
Estimate an order
get_order_preview body → 200401422500
POST
/preview/v2/orders
Create order
create_order 1 param body → 201401402403404422500503
GET
/preview/v2/orders
List orders
list_orders 12 params → 200401403422500
DELETE
/preview/v2/orders/{id}
Cancel order
cancel_order 1 param → 204401403404422500
GET
/preview/v2/orders/{id}
Get order
fetch_order 1 param → 200401403404500

Schemas 43

The contract defines 43 schemas that model the data the API accepts and returns. The most detailed are v2.OrderResponse (18 properties), v2.CreateOrderRequest (7 properties), v2.BuyOrderPreviewRequest (5 properties), v2.SellOrderPreviewRequest (5 properties). Each schema is shown below with its type and property counts.

v2.OrderPreviewNotice
ContractId
string
v2.SellOrderPreviewRequest
object
5 properties 4 required
InstanceSkuId
Accepts the canonical prefix below; additional legacy prefixes are aliased for read compatibility. Writes always emit the canonical form.
InternalServerError
object
1 property 1 required
Schedule
array
Node count over time, as a list of [startat, endat) time ranges. Example: 5 nodes from t=0 to t=3600 is [{"startat": 0, "endat": 3600, "nodecount": 5}]. starta…
OrderId
string
UnprocessableEntityError
object
1 property 1 required
v2.OrderPreviewUnavailableReason
string
v2.OrderPreviewFee
object
Fee charged on fills for the targeted instance SKU. Total fee = flatdollarspernodehour × nodecount × durationhours + percentagebps / 10000 × executiontotaldoll…
2 properties 2 required
v2.MaintenanceNoticeType
string
OrderStatus
string
The status of an order in the system. pending = not resolved/processed yet. filled = order executed. partiallyfilled = the order matched part of its requested…
v2.OrderPrincipalKind
string
Whether an order's createdby principal is a human user or an API token.
ErrorDetail
object
3 properties 2 required
ResourcePathOrId_PoolId
string
A resource path like 'sfc:pool:acme:prod:my-pool' or an ID. Resource paths are human-readable but not stable - they change when resources are renamed or moved.…
ScheduleEntry
object
A [startat, endat) time range with a fixed nodecount. endat is null only on the final entry, marking an unbounded tail.
3 properties 2 required
Requirements
object
Key/value filters on instance SKU properties. Valid keys and values are published at GET /v2/instanceskupropertycatalog. Empty map = no constraints.
v2.OrderResponse
object
18 properties 12 required
v2.BuyOrderPreviewRequest
object
5 properties 4 required
UnauthorizedError
object
1 property 1 required
v2.OrderPreviewRequest
Side
string
ServiceUnavailableError
object
1 property 1 required
v2.ListOrdersResponse
object
4 properties 3 required
PoolId
string
NotFoundError
object
1 property 1 required
PoolSummary
object
A pool referenced by id and name.
2 properties 2 required
v2.OrderFill
object
A single fill event: one contract that was produced when the order matched.
4 properties 3 required
ResourcePathOrId_ProcurementId
string
A resource path like 'sfc:procurement:acme:prod:my-procurement' or an ID. Resource paths are human-readable but not stable - they change when resources are ren…
v2.OrderPrincipal
object
The principal that placed an order. type distinguishes the two cases: a user carries email (when an email identity exists); a token carries name. The inapplica…
4 properties 2 required
CapacityId
Accepts the canonical prefix below; additional legacy prefixes are aliased for read compatibility. Writes always emit the canonical form.
Name
string
CapacitySummary
object
2 properties 2 required
InstanceSkuSummary
object
A summary of an instance SKU - its id and human-recognizable alias - embedded on resources that reference a SKU.
3 properties 3 required
DollarsPerNodeHour
string
Price rate in dollars per node-hour.
v2.OrderSortBy
string
PaymentRequiredError
object
1 property 1 required
ResourcePathOrId_WorkspaceId
string
A resource path like 'sfc:workspace:acme:my-workspace' or an ID. Resource paths are human-readable but not stable - they change when resources are renamed or m…
v2.CreateOrderRequest
object
7 properties 5 required
OrdersCursor
string
v2.OrderPreviewResponse
UnixEpoch
integer
Unix timestamp.
ForbiddenError
object
1 property 1 required

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

the-san-francisco-compute-company-orders-api-openapi.yml Raw ↑

Other APIs The San Francisco Compute Company publishes across the network.

The San Francisco Compute Company Account API
The San Francisco Compute Company Deployments API
The San Francisco Compute Company Feature Flags API
The San Francisco Compute Company Images API
The San Francisco Compute Company Instance SKU Catalog API
The San Francisco Compute Company Instance SKUs API
The San Francisco Compute Company Instance Templates API
The San Francisco Compute Company Instances API
The San Francisco Compute Company Orderbook API
The San Francisco Compute Company Pools API
The San Francisco Compute Company Procurements API
The San Francisco Compute Company Users API