{ "openapi": "3.0.1", "info": { "title": "CostGraph Pricing API", "description": "Provides API level access to the Costgraph Services.", "termsOfService": "https://costgraph.ai/terms-of-use", "contact": { "name": "Customer Support", "url": "https://costgraph.ai/support", "email": "support@costgraph.ai" }, "license": { "name": "Apache 2.0", "url": "http://www.apache.org/licenses/LICENSE-2.0.html" }, "version": "1.0" }, "servers": [ { "url": "https://pricing.baselinehq.cloud/" } ], "paths": { "/marketplace/providers/compute": { "get": { "summary": "Get your custom pricing entries", "description": "List the compute rates your organization has registered. Only your own rates are returned, never another organization's.\nFilters combine, and paging is by limit and offset.\nSuperseded by GET /v1/marketplace/compute, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum entries to return (default 500)", "schema": { "type": "integer" } }, { "name": "offset", "in": "query", "description": "Entries to skip", "schema": { "type": "integer" } }, { "name": "service", "in": "query", "description": "Filter by service", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "instance_type", "in": "query", "description": "Filter by instance type", "schema": { "type": "string" } }, { "name": "usage_type", "in": "query", "description": "Filter by usage type", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for custom pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePriceList" } } } }, "400": { "description": "Invalid limit or offset", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "summary": "Register a custom provider", "description": "Register your own compute rates so CostGraph can price machines it has no public price for, such as bare metal or a private cloud.\nAn entry is upserted on its natural key (provider, service, region, availability zone, usage type, instance type, operating system and period billing hours), so re-posting the same entry with a new cost keeps its id and reprices everything already using it. Changing any key field mints a new id, because it describes a different SKU.\nThe returned id is what you attach to a resource with the `costgraph.ai/pricing-id.compute` label or tag. Treat it as a secret you hand out deliberately: anyone holding it can pin to the rate, which is how a provider prices clusters it sells on.\nSuperseded by POST /v1/marketplace/compute, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Custom pricing request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePricesRequest" } } }, "required": true }, "responses": { "200": { "description": "Pricing response for a custom provider", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredComputePrices" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Provider and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" }, "delete": { "summary": "Delete a custom provider instance", "description": "Delete one of your compute rates by id.\nA rate a resource is already priced against cannot be deleted; the request fails while that link exists, so re-pin those resources first.\nOnce it is gone, a resource still carrying its id stops resolving a price rather than falling back to attribute matching.\nSuperseded by DELETE /v1/marketplace/compute/{id}, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "id", "in": "query", "description": "Instance ID", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for a custom provider", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredComputePrices" } } } }, "400": { "description": "Invalid id", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Provider and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Instance not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] } }, "/marketplace/providers/databases": { "get": { "summary": "Get your custom database pricing entries", "description": "List the managed database rates your organization has registered. Only your own rates are returned.\nFilters combine, and paging is by limit and offset.\nSuperseded by GET /v1/marketplace/databases, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum entries to return (default 500)", "schema": { "type": "integer" } }, { "name": "offset", "in": "query", "description": "Entries to skip", "schema": { "type": "integer" } }, { "name": "service", "in": "query", "description": "Filter by service", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "engine", "in": "query", "description": "Filter by engine", "schema": { "type": "string" } }, { "name": "edition", "in": "query", "description": "Filter by edition", "schema": { "type": "string" } }, { "name": "instance_type", "in": "query", "description": "Filter by instance type", "schema": { "type": "string" } }, { "name": "usage_type", "in": "query", "description": "Filter by usage type", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for custom database pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DatabasePriceList" } } } }, "400": { "description": "Invalid limit or offset", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "summary": "Register custom database pricing", "description": "Register your own managed database rates, keyed by engine, edition, deployment option, storage type and instance type alongside the usual provider, service and region.\nAn entry is upserted on the full natural key (provider, service, region, availability zone, usage type, engine, edition, deployment option, billing config, storage type, instance type, architecture and period billing hours), so re-posting with a new cost keeps its id; changing any key field mints a new one.\nThe returned id is what you attach with the `costgraph.ai/pricing-id.database` label or tag.\nSuperseded by POST /v1/marketplace/databases, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Custom database pricing request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DatabasePricesRequest" } } }, "required": true }, "responses": { "200": { "description": "Pricing response for custom database pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredDatabasePrices" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Provider and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" }, "delete": { "summary": "Delete a custom database pricing entry", "description": "Delete one of your managed database rates by id.\nA rate a database or one of its reports still references cannot be deleted; the request fails while that reference exists, so re-pin first.\nOnce it is gone, a database still carrying its id stops resolving a price.\nSuperseded by DELETE /v1/marketplace/databases/{id}, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "id", "in": "query", "description": "Database pricing ID", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for custom database pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredDatabasePrices" } } } }, "400": { "description": "Invalid id", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Provider and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Database pricing entry not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] } }, "/marketplace/providers/disks": { "get": { "summary": "Get your custom disk pricing entries", "description": "List the storage rates your organization has registered. Only your own rates are returned.\nFilters combine, and paging is by limit and offset.\nSuperseded by GET /v1/marketplace/disks, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum entries to return (default 500)", "schema": { "type": "integer" } }, { "name": "offset", "in": "query", "description": "Entries to skip", "schema": { "type": "integer" } }, { "name": "service", "in": "query", "description": "Filter by service", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "type", "in": "query", "description": "Filter by disk type", "schema": { "type": "string" } }, { "name": "usage_type", "in": "query", "description": "Filter by usage type", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for custom disk pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPriceList" } } } }, "400": { "description": "Invalid limit or offset", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "summary": "Register a custom disk provider", "description": "Register your own storage rates, priced per GB hour with optional IOPS and throughput components and the capacity band they apply to.\nAn entry is upserted on its natural key (provider, service, region, availability zone, disk type, usage type and period billing hours), so re-posting with a new cost keeps its id; changing a key field mints a new one.\nCapacity, IOPS and throughput bands are not part of that key, so a second band for the same disk type replaces the first: give each band its own usage type.\nThe returned id is what you attach with the `costgraph.ai/pricing-id.storage` label or tag.\nSuperseded by POST /v1/marketplace/disks, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Custom disk pricing request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPricesRequest" } } }, "required": true }, "responses": { "200": { "description": "Pricing response for a custom disk provider", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredDiskPrices" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Provider and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" }, "delete": { "summary": "Delete a custom disk provider entry", "description": "Delete one of your storage rates by id.\nA rate a volume is already priced against cannot be deleted; the request fails while that link exists, so re-pin those volumes first.\nOnce it is gone, a volume still carrying its id stops resolving a price.\nSuperseded by DELETE /v1/marketplace/disks/{id}, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "id", "in": "query", "description": "Disk pricing ID", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for a custom disk provider", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredDiskPrices" } } } }, "400": { "description": "Invalid id", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Provider and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Disk pricing entry not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] } }, "/marketplace/providers/models": { "get": { "summary": "Get your custom model pricing entries", "description": "List the live version of each model rate your organization has registered. Only your own rates are returned.\nFilters combine, and paging is by limit and offset.\nSuperseded by GET /v1/marketplace/models, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum entries to return (default 500)", "schema": { "type": "integer" } }, { "name": "offset", "in": "query", "description": "Entries to skip", "schema": { "type": "integer" } }, { "name": "model", "in": "query", "description": "Filter by model", "schema": { "type": "string" } }, { "name": "provider", "in": "query", "description": "Filter by model provider", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "token_bucket", "in": "query", "description": "Filter by token bucket", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for custom model pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ModelPriceList" } } } }, "400": { "description": "Invalid limit or offset", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "summary": "Register custom model pricing", "description": "Register custom token pricing for models you host. Entries are versioned: a price change closes the current row and opens a new one, so historic spend keeps the rate it was billed at.\nThe returned id is what you attach with the `costgraph.ai/pricing-id.model` label or tag. Each version carries its own id, so read the live entry back after a price change instead of holding on to an earlier one.\nSuperseded by POST /v1/marketplace/models, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Custom model pricing request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ModelPricesRequest" } } }, "required": true }, "responses": { "200": { "description": "Pricing response for custom model pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredModelPrices" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Host and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" }, "delete": { "summary": "Delete a custom model pricing entry", "description": "Delete one of your model rates by id. The row is closed rather than removed, so spend already priced against it keeps that rate.\nUsage still pinned to it stops resolving a price, so re-pin before deleting.\nSuperseded by DELETE /v1/marketplace/models/{id}, which returns RFC 9457 problem responses on failure.", "parameters": [ { "name": "id", "in": "query", "description": "Model pricing ID", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Pricing response for custom model pricing", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RegisteredModelPrices" } } } }, "400": { "description": "Invalid id", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Host and organization do not match", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Model pricing entry not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] } }, "/pricing": { "post": { "summary": "Get pricing for an instance", "description": "Get pricing for compute instances\nSuperseded by POST /v1/pricing/compute, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Instance", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Instance" } } }, "required": true }, "responses": { "200": { "description": "Pricing for a given instance", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePrice" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Pricing not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/pricing/compute": { "post": { "summary": "Get pricing for an instance", "description": "Get pricing for compute instances\nSuperseded by POST /v1/pricing/compute, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Instance", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Instance" } } }, "required": true }, "responses": { "200": { "description": "Pricing for a given instance", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePrice" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Pricing not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/pricing/disks": { "post": { "summary": "Get pricing for a disk", "description": "Get pricing for a disk\nSuperseded by POST /v1/pricing/disks, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Disk", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Disk" } } }, "required": true }, "responses": { "200": { "description": "Pricing for a given disk", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPrice" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Pricing not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/providers": { "get": { "summary": "Get details for the providers", "description": "Get details for the providers\nSuperseded by GET /v1/providers, which returns RFC 9457 problem responses on failure.", "responses": { "200": { "description": "List of providers", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProviderConfigs" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] } }, "/recommendations": { "post": { "summary": "Get recommendations for compute instances", "description": "Get the cheapest compute candidate per provider with savings versus the requested instance\nSuperseded by POST /v1/recommendations/compute, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Instance", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputeRecommendationRequest" } } }, "required": true }, "responses": { "200": { "description": "OK", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ComputeRecommendation" } } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/recommendations/compute": { "post": { "summary": "Get recommendations for compute instances", "description": "Get the cheapest compute candidate per provider with savings versus the requested instance\nSuperseded by POST /v1/recommendations/compute, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Instance", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputeRecommendationRequest" } } }, "required": true }, "responses": { "200": { "description": "OK", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ComputeRecommendation" } } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/recommendations/disks": { "post": { "summary": "Get recommendations for disks", "description": "Get the cheapest disk candidate per provider with savings versus the requested disk\nSuperseded by POST /v1/recommendations/disks, which returns RFC 9457 problem responses on failure.", "requestBody": { "description": "Instance", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskRecommendationRequest" } } }, "required": true }, "responses": { "200": { "description": "OK", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/DiskRecommendation" } } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "deprecated": true, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/v1/healthz": { "get": { "tags": [ "service" ], "summary": "Check the service is live", "description": "Report that the pricing service is accepting requests. No credential is required.", "responses": { "200": { "description": "The service is live", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": { "type": "string" } } } } } } } }, "/v1/marketplace/compute": { "get": { "tags": [ "marketplace" ], "summary": "List your compute prices", "description": "List the compute rates your organization has published. Only your own rates are returned, never another organization's.\nFilters combine, and paging is by limit and an opaque cursor carried in the page of the previous response.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum prices to return (default 500)", "schema": { "type": "integer" } }, { "name": "cursor", "in": "query", "description": "Cursor from the previous page", "schema": { "type": "string" } }, { "name": "service", "in": "query", "description": "Filter by service", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "instance_type", "in": "query", "description": "Filter by instance type", "schema": { "type": "string" } }, { "name": "usage_type", "in": "query", "description": "Filter by usage type", "schema": { "type": "string" } } ], "responses": { "200": { "description": "A page of your prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePricePage" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "tags": [ "marketplace" ], "summary": "Publish compute prices", "description": "Register your own compute rates so CostGraph can price machines it has no public price for, such as bare metal or a private cloud.\nAn entry is upserted on its natural key (provider, service, region, availability zone, usage type, instance type, operating system and period billing hours), so re-posting the same entry with a new cost keeps its id and reprices everything already using it. Changing any key field mints a new id, because it describes a different SKU.\nThe returned id is what you attach to a resource with the `costgraph.ai/pricing-id.compute` label or tag.", "requestBody": { "description": "Prices to publish", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePricesRequest" } } }, "required": true }, "responses": { "201": { "description": "The published prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PublishedComputePrices" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/marketplace/compute/{id}": { "get": { "tags": [ "marketplace" ], "summary": "Read one compute price", "description": "Read a single compute rate your organization has published, by its id.\nA price belonging to another organization is not visible and reads as not found.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "The price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePrice" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "delete": { "tags": [ "marketplace" ], "summary": "Delete one compute price", "description": "Delete a compute price you have published, by its id.\nUsage still pinned to it stops resolving a price, so re-pin before deleting.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "204": { "description": "The price was deleted", "content": {} }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "patch": { "tags": [ "marketplace" ], "summary": "Change one compute price", "description": "Change the rate or the descriptive fields of a compute price you have published. Send only the fields you want to change.\nThe fields that identify the price cannot be changed, because they describe a different SKU; delete the price and register a new one instead.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "requestBody": { "description": "Fields to change", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": true } } }, "required": true }, "responses": { "200": { "description": "The changed price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePrice" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/marketplace/databases": { "get": { "tags": [ "marketplace" ], "summary": "List your database prices", "description": "List the database rates your organization has published. Only your own rates are returned, never another organization's.\nFilters combine, and paging is by limit and an opaque cursor carried in the page of the previous response.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum prices to return (default 500)", "schema": { "type": "integer" } }, { "name": "cursor", "in": "query", "description": "Cursor from the previous page", "schema": { "type": "string" } }, { "name": "service", "in": "query", "description": "Filter by service", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "engine", "in": "query", "description": "Filter by engine", "schema": { "type": "string" } }, { "name": "edition", "in": "query", "description": "Filter by edition", "schema": { "type": "string" } }, { "name": "instance_type", "in": "query", "description": "Filter by instance type", "schema": { "type": "string" } }, { "name": "usage_type", "in": "query", "description": "Filter by usage type", "schema": { "type": "string" } } ], "responses": { "200": { "description": "A page of your prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DatabasePricePage" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "tags": [ "marketplace" ], "summary": "Publish database prices", "description": "Register your own managed database rates so CostGraph can price clusters it has no public price for.\nAn entry is upserted on its natural key (provider, service, region, engine, edition, instance type and usage type), so re-posting the same entry with a new cost keeps its id and reprices everything already using it.\nThe returned id is what you attach to a database with the `costgraph.ai/pricing-id.database` label or tag.", "requestBody": { "description": "Prices to publish", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DatabasePricesRequest" } } }, "required": true }, "responses": { "201": { "description": "The published prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PublishedDatabasePrices" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/marketplace/databases/{id}": { "get": { "tags": [ "marketplace" ], "summary": "Read one database price", "description": "Read a single database rate your organization has published, by its id.\nA price belonging to another organization is not visible and reads as not found.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "The price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DatabasePrice" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "delete": { "tags": [ "marketplace" ], "summary": "Delete one database price", "description": "Delete a database price you have published, by its id.\nUsage still pinned to it stops resolving a price, so re-pin before deleting.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "204": { "description": "The price was deleted", "content": {} }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "patch": { "tags": [ "marketplace" ], "summary": "Change one database price", "description": "Change the rate or the descriptive fields of a database price you have published. Send only the fields you want to change.\nThe fields that identify the price cannot be changed, because they describe a different SKU; delete the price and register a new one instead.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "requestBody": { "description": "Fields to change", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": true } } }, "required": true }, "responses": { "200": { "description": "The changed price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DatabasePrice" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/marketplace/disks": { "get": { "tags": [ "marketplace" ], "summary": "List your disk prices", "description": "List the disk rates your organization has published. Only your own rates are returned, never another organization's.\nFilters combine, and paging is by limit and an opaque cursor carried in the page of the previous response.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum prices to return (default 500)", "schema": { "type": "integer" } }, { "name": "cursor", "in": "query", "description": "Cursor from the previous page", "schema": { "type": "string" } }, { "name": "service", "in": "query", "description": "Filter by service", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "type", "in": "query", "description": "Filter by disk type", "schema": { "type": "string" } }, { "name": "usage_type", "in": "query", "description": "Filter by usage type", "schema": { "type": "string" } } ], "responses": { "200": { "description": "A page of your prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPricePage" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "tags": [ "marketplace" ], "summary": "Publish disk prices", "description": "Register your own block storage rates so CostGraph can price volumes it has no public price for.\nAn entry is upserted on its natural key (provider, service, region, availability zone, usage type, type and period billing hours), so re-posting the same entry with a new cost keeps its id and reprices everything already using it.\nThe returned id is what you attach to a volume with the `costgraph.ai/pricing-id.disk` label or tag.", "requestBody": { "description": "Prices to publish", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPricesRequest" } } }, "required": true }, "responses": { "201": { "description": "The published prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PublishedDiskPrices" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/marketplace/disks/{id}": { "get": { "tags": [ "marketplace" ], "summary": "Read one disk price", "description": "Read a single disk rate your organization has published, by its id.\nA price belonging to another organization is not visible and reads as not found.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "The price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPrice" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "delete": { "tags": [ "marketplace" ], "summary": "Delete one disk price", "description": "Delete a disk price you have published, by its id.\nUsage still pinned to it stops resolving a price, so re-pin before deleting.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "204": { "description": "The price was deleted", "content": {} }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "patch": { "tags": [ "marketplace" ], "summary": "Change one disk price", "description": "Change the rate or the descriptive fields of a disk price you have published. Send only the fields you want to change.\nThe fields that identify the price cannot be changed, because they describe a different SKU; delete the price and register a new one instead.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "requestBody": { "description": "Fields to change", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": true } } }, "required": true }, "responses": { "200": { "description": "The changed price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPrice" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/marketplace/filters/{kind}": { "get": { "tags": [ "marketplace" ], "summary": "List the filters a price kind accepts", "description": "The query parameters you can filter this kind of price by. They differ by kind because the fields that identify a price differ: compute prices carry an instance type, disk prices a disk type, database prices an engine.", "parameters": [ { "name": "kind", "in": "path", "description": "Price kind", "required": true, "schema": { "type": "string", "enum": [ "compute", "disks", "databases", "models" ] } } ], "responses": { "200": { "description": "OK", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/FilterSet" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] } }, "/v1/marketplace/models": { "get": { "tags": [ "marketplace" ], "summary": "List your model prices", "description": "List the model rates your organization has published. Only your own rates are returned, never another organization's.\nFilters combine, and paging is by limit and an opaque cursor carried in the page of the previous response.", "parameters": [ { "name": "limit", "in": "query", "description": "Maximum prices to return (default 500)", "schema": { "type": "integer" } }, { "name": "cursor", "in": "query", "description": "Cursor from the previous page", "schema": { "type": "string" } }, { "name": "model", "in": "query", "description": "Filter by model", "schema": { "type": "string" } }, { "name": "provider", "in": "query", "description": "Filter by model provider", "schema": { "type": "string" } }, { "name": "region", "in": "query", "description": "Filter by region", "schema": { "type": "string" } }, { "name": "token_bucket", "in": "query", "description": "Filter by token bucket", "schema": { "type": "string" } } ], "responses": { "200": { "description": "A page of your prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ModelPricePage" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "post": { "tags": [ "marketplace" ], "summary": "Publish model prices", "description": "Register your own token rates for models you host, so CostGraph can price calls it has no public rate for.\nEntries are versioned: a price change closes the current row and opens a new one, so spend already recorded keeps the rate it was billed at.\nThe returned id is what you attach with the `costgraph.ai/pricing-id.model` label or tag. Each version carries its own id, so read the live entry back after a price change.", "requestBody": { "description": "Prices to publish", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ModelPricesRequest" } } }, "required": true }, "responses": { "201": { "description": "The published prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PublishedModelPrices" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/marketplace/models/{id}": { "get": { "tags": [ "marketplace" ], "summary": "Read one model price", "description": "Read a single model rate your organization has published, by its id.\nA price belonging to another organization is not visible and reads as not found.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "The price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ModelPrice" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "delete": { "tags": [ "marketplace" ], "summary": "Delete one model price", "description": "Delete a model price you have published, by its id.\nUsage still pinned to it stops resolving a price, so re-pin before deleting.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "responses": { "204": { "description": "The price was deleted", "content": {} }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] }, "patch": { "tags": [ "marketplace" ], "summary": "Change one model price", "description": "Change the rate or the descriptive fields of a model price you have published. Send only the fields you want to change.\nThe fields that identify the price cannot be changed, because they describe a different SKU; delete the price and register a new one instead.", "parameters": [ { "name": "id", "in": "path", "description": "Price id", "required": true, "schema": { "type": "string" } } ], "requestBody": { "description": "Fields to change", "content": { "application/json": { "schema": { "type": "object", "additionalProperties": true } } }, "required": true }, "responses": { "200": { "description": "The changed price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ModelPrice" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal Server Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "body" } }, "/v1/pricing/compute": { "post": { "tags": [ "pricing" ], "summary": "Price a machine", "description": "Resolve the hourly rate CostGraph would bill for a machine with the given shape, in the given region and usage type.\nPrices you have published for the machine's provider are preferred over the public catalogue.", "requestBody": { "description": "Machine to price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Instance" } } }, "required": true }, "responses": { "200": { "description": "The resolved price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputePrice" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthenticated", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "No price matches the machine", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Validation failed", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/v1/pricing/disks": { "post": { "tags": [ "pricing" ], "summary": "Price a volume", "description": "Resolve the rate CostGraph would bill for a block volume of the given type and capacity, in the given region.\nPrices you have published for the volume's provider are preferred over the public catalogue.", "requestBody": { "description": "Volume to price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Disk" } } }, "required": true }, "responses": { "200": { "description": "The resolved price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskPrice" } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthenticated", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "No price matches the volume", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Validation failed", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/v1/providers": { "get": { "tags": [ "providers" ], "summary": "List the providers CostGraph prices", "description": "Return every provider the pricing catalogue covers, with the filter values each one accepts.", "responses": { "200": { "description": "The providers CostGraph prices", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ProviderConfigs" } } } }, "401": { "description": "Unauthenticated", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ] } }, "/v1/recommendations/compute": { "post": { "tags": [ "recommendations" ], "summary": "Find cheaper machines", "description": "Return the cheapest machine per provider that still meets the requested shape, with the saving against the machine you asked about.", "requestBody": { "description": "Machine to improve on", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ComputeRecommendationRequest" } } }, "required": true }, "responses": { "200": { "description": "The cheapest candidate per provider", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ComputeRecommendation" } } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthenticated", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "No candidate matches the machine", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Validation failed", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } }, "/v1/recommendations/disks": { "post": { "tags": [ "recommendations" ], "summary": "Find cheaper volumes", "description": "Return the cheapest volume per provider that still meets the requested capacity and performance, with the saving against the volume you asked about.", "requestBody": { "description": "Volume to improve on", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DiskRecommendationRequest" } } }, "required": true }, "responses": { "200": { "description": "The cheapest candidate per provider", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/DiskRecommendation" } } } } }, "400": { "description": "Invalid request body", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "401": { "description": "Unauthenticated", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "404": { "description": "No candidate matches the volume", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "422": { "description": "Validation failed", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Problem" } } } } }, "security": [ { "ApiKeyAuth": [] }, { "BearerAuth": [] } ], "x-codegen-request-body-name": "instance" } } }, "components": { "schemas": { "ComputePrice": { "type": "object", "properties": { "architecture": { "type": "string" }, "availability_zone": { "type": "string" }, "cost_per_hour": { "type": "number" }, "cpu_cores": { "type": "number" }, "cpu_cores_cost_per_hour": { "type": "number" }, "created_at": { "type": "string" }, "currency": { "type": "string" }, "gpu_cost_per_hour": { "type": "number" }, "gpu_count": { "type": "number" }, "gpu_type": { "type": "string" }, "id": { "type": "string" }, "instance_type": { "type": "string" }, "native_cost_per_hour": { "type": "number" }, "operating_system": { "type": "string" }, "period_billing_hours": { "type": "number" }, "provider": { "type": "string" }, "ram_gb": { "type": "number" }, "ram_gb_cost_per_hour": { "type": "number" }, "raw_pricing_data": { "type": "object", "properties": {} }, "region": { "type": "string" }, "service": { "type": "string" }, "tags": { "type": "object", "properties": {} }, "updated_at": { "type": "string" }, "usage_type": { "type": "string" } } }, "ComputePriceList": { "type": "object", "properties": { "providers": { "type": "array", "items": { "$ref": "#/components/schemas/ComputePrice" } } } }, "ComputePricePage": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/ComputePrice" } }, "page": { "$ref": "#/components/schemas/Page" } } }, "ComputePricesRequest": { "required": [ "entries" ], "type": "object", "properties": { "entries": { "minItems": 1, "type": "array", "items": { "$ref": "#/components/schemas/ComputePrice" } } } }, "ComputeRecommendation": { "type": "object", "properties": { "pricing": { "$ref": "#/components/schemas/ComputePrice" }, "savings": { "$ref": "#/components/schemas/types.Savings" } } }, "ComputeRecommendationRequest": { "type": "object", "properties": { "include_metadata": { "type": "boolean" }, "instance": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.Instance" }, "predicates": { "$ref": "#/components/schemas/types.Predicates" }, "usage": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.VM" } } }, "DatabasePrice": { "type": "object", "properties": { "architecture": { "type": "string" }, "availability_zone": { "type": "string" }, "billing_config": { "type": "string" }, "capacity_unit": { "type": "string" }, "cost_per_capacity_unit": { "type": "number" }, "cost_per_hour": { "type": "number" }, "cost_per_io_request": { "type": "number" }, "cost_per_iops_hour": { "type": "number" }, "cost_per_storage_gb_hour": { "type": "number" }, "cost_per_throughput_mbps_hour": { "type": "number" }, "cost_per_vcpu_license_hour": { "type": "number" }, "cpu_cores": { "type": "number" }, "cpu_cores_cost_per_hour": { "type": "number" }, "created_at": { "type": "string" }, "currency": { "type": "string" }, "deployment_option": { "type": "string" }, "edition": { "type": "string" }, "engine": { "type": "string" }, "id": { "type": "string" }, "instance_type": { "type": "string" }, "max_iops": { "type": "number" }, "max_storage_gb": { "type": "number" }, "max_throughput_mbps": { "type": "number" }, "min_iops": { "type": "number" }, "min_storage_gb": { "type": "number" }, "min_throughput_mbps": { "type": "number" }, "native_cost_per_hour": { "type": "number" }, "native_cost_per_storage_gb_hour": { "type": "number" }, "period_billing_hours": { "type": "number" }, "provider": { "type": "string" }, "ram_gb": { "type": "number" }, "ram_gb_cost_per_hour": { "type": "number" }, "raw_pricing_data": { "type": "object", "properties": {} }, "region": { "type": "string" }, "service": { "type": "string" }, "storage_type": { "type": "string" }, "tags": { "type": "object", "properties": {} }, "updated_at": { "type": "string" }, "usage_type": { "type": "string" } } }, "DatabasePriceList": { "type": "object", "properties": { "providers": { "type": "array", "items": { "$ref": "#/components/schemas/DatabasePrice" } } } }, "DatabasePricePage": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/DatabasePrice" } }, "page": { "$ref": "#/components/schemas/Page" } } }, "DatabasePricesRequest": { "required": [ "entries" ], "type": "object", "properties": { "entries": { "minItems": 1, "type": "array", "items": { "$ref": "#/components/schemas/DatabasePrice" } } } }, "Disk": { "type": "object", "properties": { "availability_zone": { "type": "string" }, "capacity_gb": { "type": "number" }, "fallback_to_base_pricing": { "type": "boolean" }, "id": { "type": "string" }, "iops": { "type": "number" }, "provider": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.Provider" }, "region": { "type": "string" }, "service": { "$ref": "#/components/schemas/types.Service" }, "throughput_mbps": { "type": "number" }, "type": { "type": "string" }, "usage_type": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.UsageType" } } }, "DiskPrice": { "type": "object", "properties": { "availability_zone": { "type": "string" }, "cost_per_gb_hour": { "type": "number" }, "cost_per_iops_hour": { "type": "number" }, "cost_per_throughput_mbps_hour": { "type": "number" }, "created_at": { "type": "string" }, "currency": { "type": "string" }, "id": { "type": "string" }, "max_capacity_gb": { "type": "number" }, "max_iops": { "type": "number" }, "max_throughput_mbps": { "type": "number" }, "min_capacity_gb": { "type": "number" }, "min_iops": { "type": "number" }, "min_throughput_mbps": { "type": "number" }, "native_cost_per_gb_hour": { "type": "number" }, "native_cost_per_iops_hour": { "type": "number" }, "native_cost_per_throughput_mbps_hour": { "type": "number" }, "period_billing_hours": { "type": "number" }, "provider": { "type": "string" }, "raw_pricing_data": { "type": "object", "properties": {} }, "region": { "type": "string" }, "service": { "type": "string" }, "tags": { "type": "object", "properties": {} }, "type": { "type": "string" }, "updated_at": { "type": "string" }, "usage_type": { "type": "string" } } }, "DiskPriceList": { "type": "object", "properties": { "providers": { "type": "array", "items": { "$ref": "#/components/schemas/DiskPrice" } } } }, "DiskPricePage": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/DiskPrice" } }, "page": { "$ref": "#/components/schemas/Page" } } }, "DiskPricesRequest": { "required": [ "entries" ], "type": "object", "properties": { "entries": { "minItems": 1, "type": "array", "items": { "$ref": "#/components/schemas/DiskPrice" } } } }, "DiskRecommendation": { "type": "object", "properties": { "pricing": { "$ref": "#/components/schemas/DiskPrice" }, "savings": { "$ref": "#/components/schemas/types.Savings" } } }, "DiskRecommendationRequest": { "type": "object", "properties": { "include_metadata": { "type": "boolean" }, "instance": { "$ref": "#/components/schemas/types.Disk" }, "predicates": { "$ref": "#/components/schemas/types.Predicates" }, "usage": { "$ref": "#/components/schemas/types.Disk" } } }, "ErrorResponse": { "type": "object", "properties": { "error": { "type": "string" } } }, "FieldError": { "type": "object", "properties": { "detail": { "type": "string" }, "pointer": { "type": "string" } } }, "FilterSet": { "type": "object", "properties": { "filters": { "type": "array", "items": { "type": "string" } }, "kind": { "type": "string" } } }, "Instance": { "type": "object", "properties": { "availability_zone": { "type": "string" }, "fallback_to_base_pricing": { "type": "boolean" }, "id": { "type": "string" }, "instance_type": { "type": "string" }, "operating_system": { "type": "string" }, "provider": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.Provider" }, "region": { "type": "string" }, "service": { "$ref": "#/components/schemas/types.Service" }, "usage_type": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.UsageType" }, "vm": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.VM" } } }, "ModelPrice": { "type": "object", "properties": { "context_limit": { "type": "integer" }, "currency": { "type": "string" }, "effective_from": { "type": "string" }, "effective_to": { "type": "string" }, "fetched_at": { "type": "string" }, "host": { "type": "string" }, "id": { "type": "string" }, "modalities_input": { "type": "array", "items": { "type": "string" } }, "modalities_output": { "type": "array", "items": { "type": "string" } }, "model": { "type": "string" }, "model_id": { "type": "string" }, "open_weights": { "type": "boolean" }, "output_limit": { "type": "integer" }, "provider": { "type": "string" }, "publisher": { "type": "string" }, "raw_pricing_data": { "$ref": "#/components/schemas/datatypes.JSON" }, "reasoning": { "type": "boolean" }, "region": { "type": "string" }, "sku_price_id": { "type": "string" }, "source": { "type": "string" }, "source_url": { "type": "string" }, "structured_output": { "type": "boolean" }, "tags": { "$ref": "#/components/schemas/datatypes.JSON" }, "token_bucket": { "type": "string" }, "tool_call": { "type": "boolean" }, "unit_price_per_mtok": { "type": "number" } } }, "ModelPriceList": { "type": "object", "properties": { "providers": { "type": "array", "items": { "$ref": "#/components/schemas/ModelPrice" } } } }, "ModelPricePage": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/ModelPrice" } }, "page": { "$ref": "#/components/schemas/Page" } } }, "ModelPricesRequest": { "required": [ "entries" ], "type": "object", "properties": { "entries": { "minItems": 1, "type": "array", "items": { "$ref": "#/components/schemas/ModelPrice" } } } }, "Page": { "type": "object", "properties": { "has_more": { "type": "boolean" }, "next_cursor": { "type": "string" } } }, "Problem": { "type": "object", "properties": { "code": { "type": "string" }, "detail": { "type": "string" }, "errors": { "type": "array", "items": { "$ref": "#/components/schemas/FieldError" } }, "instance": { "type": "string" }, "status": { "type": "integer" }, "title": { "type": "string" }, "type": { "type": "string" } } }, "ProviderConfig": { "type": "object", "properties": { "predicates": { "$ref": "#/components/schemas/types.Predicates" }, "provider": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.Provider" } } }, "ProviderConfigs": { "type": "object", "additionalProperties": { "$ref": "#/components/schemas/ProviderConfig" } }, "PublishedComputePrices": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/ComputePrice" } } } }, "PublishedDatabasePrices": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/DatabasePrice" } } } }, "PublishedDiskPrices": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/DiskPrice" } } } }, "PublishedModelPrices": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/ModelPrice" } } } }, "RegisteredComputePrices": { "type": "object", "properties": { "entries": { "type": "array", "items": { "$ref": "#/components/schemas/ComputePrice" } }, "status": { "$ref": "#/components/schemas/RegistrationStatus" } } }, "RegisteredDatabasePrices": { "type": "object", "properties": { "entries": { "type": "array", "items": { "$ref": "#/components/schemas/DatabasePrice" } }, "status": { "$ref": "#/components/schemas/RegistrationStatus" } } }, "RegisteredDiskPrices": { "type": "object", "properties": { "entries": { "type": "array", "items": { "$ref": "#/components/schemas/DiskPrice" } }, "status": { "$ref": "#/components/schemas/RegistrationStatus" } } }, "RegisteredModelPrices": { "type": "object", "properties": { "entries": { "type": "array", "items": { "$ref": "#/components/schemas/ModelPrice" } }, "status": { "$ref": "#/components/schemas/RegistrationStatus" } } }, "RegistrationStatus": { "type": "string", "enum": [ "Registered", "Deleted" ], "x-enum-varnames": [ "Registered", "Deleted" ] }, "datatypes.JSON": { "type": "object" }, "github_com_baselinehq_golang-shared_types.Instance": { "type": "object", "properties": { "availability_zone": { "type": "string" }, "fallback_to_base_pricing": { "type": "boolean" }, "id": { "type": "string" }, "instance_type": { "type": "string" }, "operating_system": { "type": "string" }, "provider": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.Provider" }, "region": { "type": "string" }, "service": { "$ref": "#/components/schemas/types.Service" }, "usage_type": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.UsageType" }, "vm": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.VM" } } }, "github_com_baselinehq_golang-shared_types.Provider": { "type": "string", "enum": [ "GCP", "AWS", "DigitalOcean", "Azure", "Hetzner", "OVHCloud", "PlanetScale", "STACKIT", "Akamai", "Base" ], "x-enum-comments": { "Base": "Base provider for default pricing, no specific cloud provider" }, "x-enum-descriptions": [ "", "", "", "", "", "", "", "", "", "Base provider for default pricing, no specific cloud provider" ], "x-enum-varnames": [ "GCP", "AWS", "DigitalOcean", "Azure", "Hetzner", "OVHCloud", "PlanetScale", "STACKIT", "Akamai", "Base" ] }, "github_com_baselinehq_golang-shared_types.UsageType": { "type": "string", "enum": [ "SPOT_PREEMPTIBLE", "ONDEMAND", "RESERVED", "ONDEMAND_CUSTOM", "SPOT_PREEMPTIBLE_CUSTOM", "RESERVED_CUSTOM", "SOLE_TENANCY", "CUSTOM", "EXTENDED" ], "x-enum-varnames": [ "SPOT_PREEMPTIBLE", "ONDEMAND", "RESERVED", "ONDEMAND_CUSTOM", "SPOT_PREEMPTIBLE_CUSTOM", "RESERVED_CUSTOM", "SOLE_TENANCY", "CUSTOM", "EXTENDED" ] }, "github_com_baselinehq_golang-shared_types.VM": { "type": "object", "properties": { "cpu_cores": { "type": "number" }, "ram_gb": { "type": "number" } } }, "types.Disk": { "type": "object", "properties": { "availability_zone": { "type": "string" }, "capacity_gb": { "type": "number" }, "fallback_to_base_pricing": { "type": "boolean" }, "id": { "type": "string" }, "iops": { "type": "number" }, "provider": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.Provider" }, "region": { "type": "string" }, "service": { "$ref": "#/components/schemas/types.Service" }, "throughput_mbps": { "type": "number" }, "type": { "type": "string" }, "usage_type": { "$ref": "#/components/schemas/github_com_baselinehq_golang-shared_types.UsageType" } } }, "types.Predicates": { "type": "object", "properties": { "availability_zones": { "type": "array", "items": { "type": "string" } }, "disk_types": { "type": "array", "items": { "type": "string" } }, "instance_types": { "type": "array", "items": { "type": "string" } }, "operating_systems": { "type": "array", "items": { "type": "string" } }, "providers": { "type": "array", "items": { "type": "string" } }, "regions": { "type": "array", "items": { "type": "string" } }, "services": { "type": "array", "items": { "type": "string" } }, "usage_types": { "type": "array", "items": { "type": "string" } } } }, "types.Savings": { "type": "object", "properties": { "amount_per_hour": { "type": "number" }, "amount_per_month": { "type": "number" }, "amount_per_year": { "type": "number" }, "percentage": { "type": "number" } } }, "types.Service": { "type": "string", "enum": [ "ComputeEngine", "AmazonEC2", "Droplet", "AzureCompute", "AzureManagedDisks", "HetznerCompute", "OVHPublicCloud", "BaseCompute", "BaseDisks", "AmazonEBS", "AmazonRDS", "AuroraDSQL", "CloudSQL", "AlloyDB", "CloudSpanner", "AzureDatabaseForPostgreSQL", "AzureDatabaseForMySQL", "AzureSQLDatabase", "AzureSQLManagedInstance", "PlanetScale", "ComputeEnginePersistentDisk", "STACKITCompute", "STACKITBlockStorage", "STACKITDatabase", "AkamaiLinode", "AkamaiBlockStorage", "AkamaiDatabase" ], "x-enum-varnames": [ "ComputeEngine", "AmazonEC2", "Droplet", "AzureCompute", "AzureManagedDisks", "HetznerCompute", "OVHPublicCloud", "BaseCompute", "BaseDisks", "AmazonEBS", "AmazonRDS", "AuroraDSQL", "CloudSQL", "AlloyDB", "CloudSpanner", "AzureDatabaseForPostgreSQL", "AzureDatabaseForMySQL", "AzureSQLDatabase", "AzureSQLManagedInstance", "PlanetScaleDB", "ComputeEnginePersistentDisk", "STACKITCompute", "STACKITBlockStorage", "STACKITDatabase", "AkamaiLinode", "AkamaiBlockStorage", "AkamaiDatabase" ] } }, "securitySchemes": { "ApiKeyAuth": { "type": "apiKey", "description": "API key with \"bl_\" prefix (e.g. \"bl_\")", "name": "X-API-Key", "in": "header" }, "BearerAuth": { "type": "apiKey", "description": "Bearer token for authentication (e.g. \"Bearer \")", "name": "Authorization", "in": "header" } } }, "x-original-swagger-version": "2.0" }