GCO Manifest Processor API — API spec sheet¶
Service manifest-processor · OpenAPI 3.1.0 · API version 2.0.0 · 37 endpoints · 11 schemas
Kubernetes manifest submission and management service for GCO (Global Capacity Orchestrator on AWS)
- Machine-readable document:
docs/openapi/manifest-processor.json— the FastAPIapp.openapi()export (scripts/generate_openapi.py) this sheet is rendered from - Interactive console (Swagger UI): https://aws-solutions-library-samples.github.io/global-capacity-orchestrator-on-aws/swagger/manifest-processor/
- Catalogue index: README.md · interaction diagram
Endpoints¶
| Method | Path | Summary | Tags |
|---|---|---|---|
GET |
/ |
Root | Info |
GET |
/api/v1/cost/reports |
List Cost Reports | Cost |
POST |
/api/v1/cost/reports |
Generate Cost Report | Cost |
GET |
/api/v1/cost/status |
Get Cost Status | Cost |
GET |
/api/v1/health |
Health Check | Health |
GET |
/api/v1/jobs |
List Jobs | Jobs |
DELETE |
/api/v1/jobs |
Bulk Delete Jobs | Jobs |
POST |
/api/v1/jobs/from-template/{name} |
Create Job From Template | Templates |
GET |
/api/v1/jobs/{namespace}/{name} |
Get Job | Jobs |
DELETE |
/api/v1/jobs/{namespace}/{name} |
Delete Job | Jobs |
GET |
/api/v1/jobs/{namespace}/{name}/events |
Get Job Events | Jobs |
GET |
/api/v1/jobs/{namespace}/{name}/logs |
Get Job Logs | Jobs |
GET |
/api/v1/jobs/{namespace}/{name}/metrics |
Get Job Metrics | Jobs |
GET |
/api/v1/jobs/{namespace}/{name}/pods |
Get Job Pods | Jobs |
GET |
/api/v1/jobs/{namespace}/{name}/pods/{pod_name}/logs |
Get Pod Logs | Jobs |
POST |
/api/v1/jobs/{namespace}/{name}/retry |
Retry Job | Jobs |
POST |
/api/v1/manifests |
Submit Manifests | Manifests |
POST |
/api/v1/manifests/validate |
Validate Manifests | Manifests |
GET |
/api/v1/manifests/{namespace}/{name} |
Get Resource Status | Manifests |
DELETE |
/api/v1/manifests/{namespace}/{name} |
Delete Resource | Manifests |
GET |
/api/v1/policy |
Get Job Validation Policy | Health |
GET |
/api/v1/queue/jobs |
List Queued Jobs | Job Queue |
POST |
/api/v1/queue/jobs |
Submit Job To Queue | Job Queue |
GET |
/api/v1/queue/jobs/{job_id} |
Get Queued Job | Job Queue |
DELETE |
/api/v1/queue/jobs/{job_id} |
Cancel Queued Job | Job Queue |
POST |
/api/v1/queue/poll |
Poll And Process Jobs | Job Queue |
GET |
/api/v1/queue/stats |
Get Queue Stats | Job Queue |
GET |
/api/v1/status |
Get Service Status | Health |
GET |
/api/v1/templates |
List Templates | Templates |
POST |
/api/v1/templates |
Create Template | Templates |
GET |
/api/v1/templates/{name} |
Get Template | Templates |
DELETE |
/api/v1/templates/{name} |
Delete Template | Templates |
GET |
/api/v1/webhooks |
List Webhooks | Webhooks |
POST |
/api/v1/webhooks |
Create Webhook | Webhooks |
DELETE |
/api/v1/webhooks/{webhook_id} |
Delete Webhook | Webhooks |
GET |
/healthz |
Kubernetes Health Check | Health |
GET |
/readyz |
Kubernetes Readiness Check | Health |
Endpoint details¶
GET /¶
Root endpoint with basic service information and API overview.
- Operation ID:
root__get - Tags: Info
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: object (free-form) |
GET /api/v1/cost/reports¶
List this region's most recent cost report objects in S3.
- Operation ID:
list_cost_reports_api_v1_cost_reports_get - Tags: Cost
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
adhoc |
query | boolean | no | false |
— | List ad-hoc instead of scheduled reports |
limit |
query | integer | no | 50 |
≥ 1; ≤ 1000 | Maximum objects returned |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/cost/reports¶
Generate an ad-hoc cost report for the trailing window.
- Operation ID:
generate_cost_report_api_v1_cost_reports_post - Tags: Cost
Request body (required): application/json: CostReportRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/cost/status¶
Cost monitoring status for this region, including OpenCost health.
- Operation ID:
get_cost_status_api_v1_cost_status_get - Tags: Cost
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
GET /api/v1/health¶
Health check endpoint for load balancer health checks.
- Operation ID:
health_check_api_v1_health_get - Tags: Health
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
GET /api/v1/jobs¶
List Kubernetes Jobs with pagination and filtering.
- Operation ID:
list_jobs_api_v1_jobs_get - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
query | string (nullable) | no | — | — | Filter by namespace |
status |
query | string (nullable) | no | — | — | Filter by status |
limit |
query | integer | no | 50 |
≥ 1; ≤ 1000 | Maximum number of jobs to return |
offset |
query | integer | no | 0 |
≥ 0 | Number of jobs to skip |
sort |
query | string | no | "createdAt:desc" |
— | Sort field and order (field:asc|desc) |
label_selector |
query | string (nullable) | no | — | max length 1024 | Comma-separated exact-match label filters (key=value only) |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
DELETE /api/v1/jobs¶
Bulk delete jobs based on filters.
- Operation ID:
bulk_delete_jobs_api_v1_jobs_delete - Tags: Jobs
Request body (required): application/json: BulkDeleteRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/jobs/from-template/{name}¶
Create a job from a template with parameter substitution.
- Operation ID:
create_job_from_template_api_v1_jobs_from_template__name__post - Tags: Templates
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
name |
path | string | yes | — | — | — |
Request body (required): application/json: JobFromTemplateRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/jobs/{namespace}/{name}¶
Get details of a specific Job, including where its pods were scheduled.
- Operation ID:
get_job_api_v1_jobs__namespace___name__get - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
DELETE /api/v1/jobs/{namespace}/{name}¶
Delete a Job, optionally requiring its immutable Kubernetes UID.
- Operation ID:
delete_job_api_v1_jobs__namespace___name__delete - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
expected_uid |
query | string (nullable) | no | — | min length 1; max length 128 | Optional immutable Kubernetes UID deletion precondition |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/jobs/{namespace}/{name}/events¶
Get events related to a Job.
- Operation ID:
get_job_events_api_v1_jobs__namespace___name__events_get - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/jobs/{namespace}/{name}/logs¶
Get logs from a Job's pods.
- Operation ID:
get_job_logs_api_v1_jobs__namespace___name__logs_get - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
container |
query | string (nullable) | no | — | — | Container name (for multi-container pods) |
tail |
query | integer | no | 100 |
≥ 1; ≤ 10000 | Number of lines from the end |
previous |
query | boolean | no | false |
— | Get logs from previous terminated container |
since_seconds |
query | integer (nullable) | no | — | ≥ 1 | Only return logs newer than N seconds |
timestamps |
query | boolean | no | false |
— | Include timestamps in log lines |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/jobs/{namespace}/{name}/metrics¶
Get resource usage metrics for a Job's pods.
- Operation ID:
get_job_metrics_api_v1_jobs__namespace___name__metrics_get - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/jobs/{namespace}/{name}/pods¶
Get pods belonging to a Job, with the hardware each one landed on.
- Operation ID:
get_job_pods_api_v1_jobs__namespace___name__pods_get - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/jobs/{namespace}/{name}/pods/{pod_name}/logs¶
Get logs from a specific pod belonging to a Job.
- Operation ID:
get_pod_logs_api_v1_jobs__namespace___name__pods__pod_name__logs_get - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
pod_name |
path | string | yes | — | — | — |
container |
query | string (nullable) | no | — | — | Container name |
tail |
query | integer | no | 100 |
≥ 1; ≤ 10000 | Number of lines from the end |
previous |
query | boolean | no | false |
— | Get logs from previous terminated container |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/jobs/{namespace}/{name}/retry¶
Retry a failed job by creating a new job from its spec.
- Operation ID:
retry_job_api_v1_jobs__namespace___name__retry_post - Tags: Jobs
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/manifests¶
Submit Kubernetes manifests for processing.
- Operation ID:
submit_manifests_api_v1_manifests_post - Tags: Manifests
Request body (required): application/json: ManifestSubmissionAPIRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/manifests/validate¶
Validate manifests without applying them.
- Operation ID:
validate_manifests_api_v1_manifests_validate_post - Tags: Manifests
Request body (required): application/json: ManifestSubmissionAPIRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/manifests/{namespace}/{name}¶
Get the status of a specific resource.
- Operation ID:
get_resource_status_api_v1_manifests__namespace___name__get - Tags: Manifests
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
api_version |
query | string | no | "apps/v1" |
— | Kubernetes API version |
kind |
query | string | no | "Deployment" |
— | Resource kind |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
DELETE /api/v1/manifests/{namespace}/{name}¶
Delete a specific resource from the cluster.
- Operation ID:
delete_resource_api_v1_manifests__namespace___name__delete - Tags: Manifests
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
path | string | yes | — | — | — |
name |
path | string | yes | — | — | — |
api_version |
query | string | no | "apps/v1" |
— | Kubernetes API version |
kind |
query | string | no | "Deployment" |
— | Resource kind |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/policy¶
The validation policy this region actually enforces, as deployed.
Answers "will this cluster admit the job I am about to pay to run?" before submission, so a policy conflict surfaces at plan time instead of after a region has been provisioned and billed.
Reads the live ManifestProcessor instance rather than any config file.
A local cdk.json is the input to a deploy, not the state of one:
the cluster may have been deployed from a different checkout, and CDK
augments trusted_registries with the project's own ECR hostnames at
synth time, so the effective allowlist is strictly larger than the
configured one.
Three layers govern admission and all three are reported:
policy— the front-door checks the manifest processor and the SQS queue processor both apply (they read the same env vars, so neither submission path is a bypass).cluster_enforcement.limit_ranges— per-container ceilings.cluster_enforcement.resource_quotas— namespace aggregate ceilings.
A manifest must clear all three. Layers 2 and 3 are read live from the
Kubernetes API and degrade to status="unavailable" rather than
failing the whole response.
- Operation ID:
get_job_validation_policy_api_v1_policy_get - Tags: Health
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: object (free-form) |
GET /api/v1/queue/jobs¶
List one bounded page of jobs with optional filters.
- Operation ID:
list_queued_jobs_api_v1_queue_jobs_get - Tags: Job Queue
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
target_region |
query | string (nullable) | no | — | — | Filter by target region |
status |
query | string (nullable) | no | — | — | Filter by status |
namespace |
query | string (nullable) | no | — | — | Filter by namespace |
limit |
query | integer | no | 100 |
≥ 1; ≤ 1000 | Maximum results |
cursor |
query | string (nullable) | no | — | max length 2048 | Opaque continuation cursor returned by the previous page |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/queue/jobs¶
Submit one validated batch/v1 Job exactly once.
- Operation ID:
submit_job_to_queue_api_v1_queue_jobs_post - Tags: Job Queue
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
Idempotency-Key |
header | string (nullable) | no | — | — | Stable key for safely replaying an identical submission |
Request body (required): application/json: QueuedJobRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/queue/jobs/{job_id}¶
Get details of a specific queued job.
- Operation ID:
get_queued_job_api_v1_queue_jobs__job_id__get - Tags: Job Queue
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
job_id |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
DELETE /api/v1/queue/jobs/{job_id}¶
Cancel a job only while it remains unclaimed in the queue.
- Operation ID:
cancel_queued_job_api_v1_queue_jobs__job_id__delete - Tags: Job Queue
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
job_id |
path | string | yes | — | — | — |
reason |
query | string (nullable) | no | — | — | Cancellation reason |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/queue/poll¶
Run one immediate queue-worker pass for this region.
The manifest API also runs this same processor continuously when the
deployment enables CENTRAL_QUEUE_WORKER_ENABLED. This endpoint remains
useful for an authenticated operator-triggered pass and diagnostics.
- Operation ID:
poll_and_process_jobs_api_v1_queue_poll_post - Tags: Job Queue
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
limit |
query | integer | no | 5 |
≥ 1; ≤ 20 | Maximum jobs to process |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/queue/stats¶
Get job queue statistics by region and status.
- Operation ID:
get_queue_stats_api_v1_queue_stats_get - Tags: Job Queue
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
GET /api/v1/status¶
Service status endpoint with detailed information.
- Operation ID:
get_service_status_api_v1_status_get - Tags: Health
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: object (free-form) |
GET /api/v1/templates¶
List all job templates.
- Operation ID:
list_templates_api_v1_templates_get - Tags: Templates
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
POST /api/v1/templates¶
Create a new job template.
- Operation ID:
create_template_api_v1_templates_post - Tags: Templates
Request body (required): application/json: JobTemplateRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/templates/{name}¶
Get a specific job template.
- Operation ID:
get_template_api_v1_templates__name__get - Tags: Templates
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
name |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
DELETE /api/v1/templates/{name}¶
Delete a job template.
- Operation ID:
delete_template_api_v1_templates__name__delete - Tags: Templates
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
name |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /api/v1/webhooks¶
List all registered webhooks.
- Operation ID:
list_webhooks_api_v1_webhooks_get - Tags: Webhooks
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
namespace |
query | string (nullable) | no | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
POST /api/v1/webhooks¶
Register a new webhook for job events.
- Operation ID:
create_webhook_api_v1_webhooks_post - Tags: Webhooks
Request body (required): application/json: WebhookRequest
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
DELETE /api/v1/webhooks/{webhook_id}¶
Delete a webhook.
- Operation ID:
delete_webhook_api_v1_webhooks__webhook_id__delete - Tags: Webhooks
Parameters
| Name | In | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|---|
webhook_id |
path | string | yes | — | — | — |
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: any |
422 |
Validation Error | application/json: HTTPValidationError |
GET /healthz¶
Kubernetes-style liveness probe.
- Operation ID:
kubernetes_health_check_healthz_get - Tags: Health
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: object of string |
GET /readyz¶
Kubernetes readiness includes the enabled queue worker task.
- Operation ID:
kubernetes_readiness_check_readyz_get - Tags: Health
Responses
| Status | Description | Content |
|---|---|---|
200 |
Successful Response | application/json: object of string |
Schemas¶
BulkDeleteRequest¶
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
dry_run |
boolean | no | false |
— | If true, only return what would be deleted |
label_selector |
string (nullable) | no | — | max length 1024 | Comma-separated exact-match label filters (key=value only) |
namespace |
string (nullable) | no | — | — | Filter by namespace |
older_than_days |
integer (nullable) | no | — | ≥ 1.0; ≤ 365.0 | Delete jobs older than N days |
status |
JobStatus (nullable) |
no | — | — | Filter by status |
Example:
{
"dry_run": false,
"namespace": "gco-jobs",
"older_than_days": 7,
"status": "completed"
}
CostReportRequest¶
Request body for POST /api/v1/cost/reports.
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
include_rows |
boolean | no | false |
— | Include the normalized allocation rows in the response |
window_hours |
integer | no | 24 |
≥ 1.0; ≤ 168.0 | Trailing window the ad-hoc report covers, in hours |
HTTPValidationError¶
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
detail |
array of ValidationError |
no | — | — | — |
JobFromTemplateRequest¶
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
name |
string | yes | — | min length 1; max length 63 | Job name |
namespace |
string | no | "gco-jobs" |
— | Target namespace |
parameters |
object (free-form) (nullable) | no | — | — | Parameter overrides |
Example:
{
"name": "my-training-job",
"namespace": "gco-jobs",
"parameters": {
"image": "my-custom-image:v1"
}
}
JobStatus¶
- Type: enum:
"pending","running","completed","succeeded","failed"
JobTemplateRequest¶
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
description |
string (nullable) | no | — | — | Template description |
manifest |
object (free-form) | yes | — | — | Job manifest template |
name |
string | yes | — | min length 1; max length 63 | Template name |
parameters |
object (free-form) (nullable) | no | — | — | Default parameter values |
Example:
{
"description": "Template for GPU training jobs",
"manifest": {
"apiVersion": "batch/v1",
"kind": "Job",
"metadata": {
"name": "{{name}}"
}
},
"name": "gpu-training-template",
"parameters": {
"image": "pytorch/pytorch:latest"
}
}
ManifestSubmissionAPIRequest¶
API model for manifest submission requests.
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
dry_run |
boolean | no | false |
— | If true, validate manifests without applying them |
manifests |
array of object (free-form) | yes | — | — | List of Kubernetes manifests to apply |
namespace |
string (nullable) | no | — | — | Default namespace for resources without namespace specified |
validate |
boolean | no | true |
— | If true, perform validation checks on manifests |
Example:
{
"dry_run": false,
"manifests": [
{
"apiVersion": "batch/v1",
"kind": "Job",
"metadata": {
"name": "example"
}
}
],
"namespace": "gco-jobs"
}
QueuedJobRequest¶
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
labels |
object of string (nullable) | no | — | — | Optional labels for filtering |
manifest |
object (free-form) | yes | — | — | Kubernetes job manifest |
max_spot_price |
number (nullable) | no | — | > 0.0 | Optional spot price cap in USD/hour. The job is not dispatched until the current spot price of spot_instance_type in the target region drops to or below this value. Requires spot_instance_type. |
namespace |
string | no | "gco-jobs" |
— | Kubernetes namespace |
priority |
integer | no | 0 |
≥ 0.0; ≤ 100.0 | Job priority (higher = more important) |
spot_instance_type |
string (nullable) | no | — | — | EC2 instance type whose spot price gates dispatch (e.g. g5.xlarge). Requires max_spot_price. |
target_region |
string | yes | — | — | Target region for job execution |
Example:
{
"manifest": {
"apiVersion": "batch/v1",
"kind": "Job",
"metadata": {
"name": "my-training-job"
}
},
"max_spot_price": 0.5,
"namespace": "gco-jobs",
"priority": 10,
"spot_instance_type": "g5.xlarge",
"target_region": "us-east-1"
}
ValidationError¶
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
ctx |
object | no | — | — | — |
input |
any | no | — | — | — |
loc |
array of string or integer | yes | — | — | — |
msg |
string | yes | — | — | — |
type |
string | yes | — | — | — |
WebhookEvent¶
- Type: enum:
"job.completed","job.failed","job.started"
WebhookRequest¶
| Property | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
events |
array of WebhookEvent |
yes | — | — | Events to subscribe to |
namespace |
string (nullable) | no | — | — | Filter by namespace (optional) |
secret |
string (nullable) | no | — | — | Secret for HMAC signature (optional) |
url |
string | yes | — | — | Webhook URL to call |
Example:
{
"events": [
"job.completed",
"job.failed"
],
"namespace": "gco-jobs",
"url": "https://example.com/webhook"
}