DEVELOPER · REST API REFERENCE

API Catalog

Explore machine-readable endpoints for health diagnostics, pricing scopes, dynamic SKU discovery, architectural cost estimates, and price sheet synchronization.

← Back to Price Console

INTERACTIVE ENVIRONMENT

Target host and authentication

Configure your target server and bearer token to dynamically update all code snippets across the catalog in real time.

REST ENDPOINTS

Available API Reference

Select any endpoint from the catalog to jump directly to its specification and code examples.

HEALTH & DIAGNOSTICS

GET /api/health

200 OK

Returns service status, local Azure CLI authentication status, SQLite database timestamps, and active pricing snapshots.


                
Sample Response (200 OK)
{ "ok": true, "version": "v0.1.0", "status": "ok", "azure_cli": { "available": true, "authenticated": true } }

PRICING SCOPES

GET /api/pricing/scopes

200 OK

Lists all configured contract pricing scopes (e.g. EA Enrollment ea:65220517) with currency, provider type, and active status.


                
Sample Response (200 OK)
{ "ok": true, "scopes": [ { "scope_id": "ea:65220517", "currency": "BRL", "active": true } ] }

PRICING SCOPES

GET /api/pricing/scopes/{scope}/sync

200 OK

Returns current synchronization state, row count, and active snapshot metadata for a specific pricing scope.

ParameterTypeDescription
scope Requiredstring (path)Scope identifier (e.g. ea:65220517)

                
Sample Response (200 OK)
{ "ok": true, "scope_id": "ea:65220517", "snapshot": { "row_count": 107065, "status": "completed" } }

PRODUCT CATALOG

GET /api/catalog/products

200 OK

Lists product definitions supported by the pricing engine (virtual_machine, managed_disk, sql_database).


                
Sample Response (200 OK)
{ "ok": true, "products": [ { "id": "virtual_machine", "label": "Virtual Machine" } ] }

PRODUCT CATALOG

GET /api/catalog/products/{id}/options/{field}

200 OK

Returns dynamic options for dropdown fields. For VM shapes (field=sku), returns complete shapes across all generations (v1 to v7) with vCPUs, RAM and EA availability.

ParameterTypeDescription
region Requiredstring (query)ARM region (e.g. brazilsouth, eastus)
os Optionalstring (query)Operating system (linux or windows)

                
Sample Response (200 OK)
{ "ok": true, "options": [ { "value": "Standard_D4s_v5", "label": "Standard_D4s_v5 (4 vCPU · 16 GB RAM)" } ] }

PRODUCT CATALOG

GET /api/skus

200 OK

Quick shape list for a region annotated with hardware specifications and pricing source indicators.


                
Sample Response (200 OK)
{ "ok": true, "region": "brazilsouth", "skus": [ { "name": "Standard_D4s_v5", "vcpus": 4, "memory_gb": 16.0 } ] }

ESTIMATES & CALCULATIONS

POST /api/estimate

200 OK

Calculates a composite architecture estimate comparing Retail vs negotiated EA Contract across PAYG, 1Y RI, 3Y RI, and Savings Plans.

FieldTypeDescription
pricing_scope Requiredstring (body)Scope identifier (e.g. ea:65220517)
lines Requiredarray (body)Array of product configuration line items

                
Sample Response (200 OK)
{ "ok": true, "currency": "BRL", "totals": { "retail": { "payg_monthly": 2450.80 }, "corporate": { "payg_monthly": 1820.50 } } }

ESTIMATES & CALCULATIONS

GET /api/estimate

200 OK

Quick single-line estimate calculation using URL query parameters.


                
Sample Response (200 OK)
{ "ok": true, "currency": "BRL", "totals": { "corporate": { "payg_monthly": 910.25 } } }

ENTERPRISE AGREEMENT (EA)

GET /api/ea/meters

200 OK

Search and filter corporate negotiated price sheet meters by text query, category, and meter location.


                
Sample Response (200 OK)
{ "ok": true, "count": 4, "rows": [ { "meterId": "6c6fb48f-4ee0-555e-a5bc-4a4f0b2fe489", "meterName": "D4s v5", "unitPrice": 175.66 } ] }

ENTERPRISE AGREEMENT (EA)

POST /api/ea/calculate

200 OK

Calculates monthly cost for a specific corporate EA meter given quantity and hours.


                
Sample Response (200 OK)
{ "ok": true, "monthly_cost": 175.66, "currency": "BRL" }

DATA SYNCHRONIZATION

POST /api/sync/billing

200 OK

Triggers an automated background pull of the Billing Account Price Sheet from Azure.


                
Sample Response (200 OK)
{ "ok": true, "status": "completed", "items": 107065 }

DATA SYNCHRONIZATION

POST /api/sync/retail

200 OK

Triggers an automated background pull of the latest Retail prices snapshot.


                
Sample Response (200 OK)
{ "ok": true, "status": "completed" }

DATA SYNCHRONIZATION

POST /api/import/ea-pricesheet

200 OK

Uploads and ingests a ZIP or CSV file exported from the Azure Portal for manual pricing update.


                
Sample Response (200 OK)
{ "ok": true, "status": "completed", "row_count": 107065 }