Billing
These are the endpoints for Billing. More information coming soon.
GET
List billing accounts
Description for this endpoint is coming soon.
Path attributes
- Name
pageToken
- Type
- string
- Description
- Name
pageSize
- Type
- integer
- Description
Request
GET
/v1/billing-accountscurl 'https://rest.compute.cudo.org/v1/billing-accounts' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"billingAccounts": [
{
"id": "string",
"createTime": "string",
"displayName": "string",
"stripeRef": "string",
"createBy": "string",
"monthlySpend": "string",
"hourlySpendRate": "string",
"taxIds": [
{
"id": "string",
"type": "string",
"value": "string"
}
],
"taxId": {
"id": "string",
"type": "string",
"value": "string"
},
"invoiceTime": "string",
"billingThreshold": {
"value": "string"
},
"monthlySpendLimit": {
"value": "string"
},
"hourlySpendLimit": {
"value": "string"
},
"nextInvoiceTotal": {
"value": "string"
},
"creditBalance": {
"value": "string"
},
"creditBalanceRecharge": {
"low": {
"value": "string"
},
"high": {
"value": "string"
},
"autoRecharge": "boolean",
"transaction": {
"id": "string",
"amount": {
"value": "string"
},
"description": "string",
"createTime": "string",
"status": "string",
"succeeded": "boolean",
"latestCharge": {
"amount": {
"value": "string"
},
"createTime": "string",
"paid": "boolean",
"refunded": "boolean",
"status": "string",
"failureCode": "string"
},
"lastPaymentError": {
"code": "string",
"declineCode": "string"
}
}
},
"billingAddress": {
"name": "string",
"phone": "string",
"city": "string",
"line1": "string",
"line2": "string",
"state": "string",
"postalCode": "string",
"country": "string"
},
"state": "string",
"paymentTerms": "string"
}
],
"pageToken": "string",
"pageSize": "integer"
}
POST
Create a billing account
Description for this endpoint is coming soon.
Request
POST
/v1/billing-accountscurl 'https://rest.compute.cudo.org/v1/billing-accounts' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
--data-raw '{
"displayName": "string",
"invoiceName": "string",
"email": "string",
"taxIds": "array",
"taxId": "object",
"referral": "string",
"billingAddress": "object"
}'
Response
{
"id": "string",
"createTime": "string",
"displayName": "string",
"stripeRef": "string",
"createBy": "string",
"monthlySpend": "string",
"hourlySpendRate": "string",
"taxIds": [
{
"id": "string",
"type": "string",
"value": "string"
}
],
"taxId": {
"id": "string",
"type": "string",
"value": "string"
},
"invoiceTime": "string",
"billingThreshold": {
"value": "string"
},
"monthlySpendLimit": {
"value": "string"
},
"hourlySpendLimit": {
"value": "string"
},
"nextInvoiceTotal": {
"value": "string"
},
"creditBalance": {
"value": "string"
},
"creditBalanceRecharge": {
"low": {
"value": "string"
},
"high": {
"value": "string"
},
"autoRecharge": "boolean",
"transaction": {
"id": "string",
"amount": {
"value": "string"
},
"description": "string",
"createTime": "string",
"status": "string",
"succeeded": "boolean",
"latestCharge": {
"amount": {
"value": "string"
},
"createTime": "string",
"paid": "boolean",
"refunded": "boolean",
"status": "string",
"failureCode": "string"
},
"lastPaymentError": {
"code": "string",
"declineCode": "string"
}
}
},
"billingAddress": {
"name": "string",
"phone": "string",
"city": "string",
"line1": "string",
"line2": "string",
"state": "string",
"postalCode": "string",
"country": "string"
},
"state": "string",
"paymentTerms": "string"
}
GET
List invoices
Description for this endpoint is coming soon.
Path attributes
- Name
id
- Type
- string
- Description
- Name
pageSize
- Type
- integer
- Description
- Name
startingAfter
- Type
- string
- Description
- Name
status
- Type
- string
- Description
Request
GET
/v1/billing-accounts/invoicescurl 'https://rest.compute.cudo.org/v1/billing-accounts/invoices' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"invoices": [
{
"id": "string",
"amountDue": "string",
"amountPaid": "string",
"amountRemaining": "string",
"created": "string",
"description": "string",
"currency": "string",
"hostedInvoiceUrl": "string",
"status": "string",
"dueDate": "string",
"paidDate": "string",
"billingReason": "string",
"autoAdvance": "boolean",
"periodStart": "string",
"periodEnd": "string",
"number": "string",
"subtotalExcludingTax": "string",
"subtotal": "string",
"totalExcludingTax": "string",
"tax": "string",
"total": "string"
}
],
"hasMore": "boolean"
}
GET
Get outstanding invoices
Description for this endpoint is coming soon.
Request
GET
/v1/billing-accounts/invoices/outstandingcurl 'https://rest.compute.cudo.org/v1/billing-accounts/invoices/outstanding' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"invoices": [
{
"id": "string",
"amountDue": "string",
"amountPaid": "string",
"amountRemaining": "string",
"created": "string",
"description": "string",
"currency": "string",
"hostedInvoiceUrl": "string",
"status": "string",
"dueDate": "string",
"paidDate": "string",
"billingReason": "string",
"autoAdvance": "boolean",
"periodStart": "string",
"periodEnd": "string",
"number": "string",
"subtotalExcludingTax": "string",
"subtotal": "string",
"totalExcludingTax": "string",
"tax": "string",
"total": "string"
}
]
}
PATCH
Update billing account
Description for this endpoint is coming soon.
Body attributes
- Name
billingAccount
- Type
- object
- Description
- Name
updateMask
- Type
- string
- Description
Path attributes
- Name
billingAccount.id
- Type
- string
- Description
Request
PATCH
/v1/billing-accounts/{billingAccount.id}curl 'https://rest.compute.cudo.org/v1/billing-accounts/{billingAccount.id}' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
--data-raw '{
"billingAccount": "object",
"updateMask": "string"
}'
Response
{
"id": "string",
"createTime": "string",
"displayName": "string",
"stripeRef": "string",
"createBy": "string",
"monthlySpend": "string",
"hourlySpendRate": "string",
"taxIds": [
{
"id": "string",
"type": "string",
"value": "string"
}
],
"taxId": {
"id": "string",
"type": "string",
"value": "string"
},
"invoiceTime": "string",
"billingThreshold": {
"value": "string"
},
"monthlySpendLimit": {
"value": "string"
},
"hourlySpendLimit": {
"value": "string"
},
"nextInvoiceTotal": {
"value": "string"
},
"creditBalance": {
"value": "string"
},
"creditBalanceRecharge": {
"low": {
"value": "string"
},
"high": {
"value": "string"
},
"autoRecharge": "boolean",
"transaction": {
"id": "string",
"amount": {
"value": "string"
},
"description": "string",
"createTime": "string",
"status": "string",
"succeeded": "boolean",
"latestCharge": {
"amount": {
"value": "string"
},
"createTime": "string",
"paid": "boolean",
"refunded": "boolean",
"status": "string",
"failureCode": "string"
},
"lastPaymentError": {
"code": "string",
"declineCode": "string"
}
}
},
"billingAddress": {
"name": "string",
"phone": "string",
"city": "string",
"line1": "string",
"line2": "string",
"state": "string",
"postalCode": "string",
"country": "string"
},
"state": "string",
"paymentTerms": "string"
}
GET
Get spend details
Description for this endpoint is coming soon.
Path attributes
- Name
billingAccountId
- Type
- string
- Description
- Name
startTime
- Type
- string
- Description
- Name
endTime
- Type
- string
- Description
Request
GET
/v1/billing-accounts/{billingAccountId}/spend/detailscurl 'https://rest.compute.cudo.org/v1/billing-accounts/{billingAccountId}/spend/details' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"spend": [
{
"projectId": "string",
"description": "string",
"quantity": "number",
"unit": "string",
"unitAmount": {
"value": "string"
},
"amount": {
"value": "string"
}
}
]
}
GET
Get a billing account
Request
GET
/v1/billing-accounts/{id}curl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"id": "string",
"createTime": "string",
"displayName": "string",
"stripeRef": "string",
"createBy": "string",
"monthlySpend": "string",
"hourlySpendRate": "string",
"taxIds": [
{
"id": "string",
"type": "string",
"value": "string"
}
],
"taxId": {
"id": "string",
"type": "string",
"value": "string"
},
"invoiceTime": "string",
"billingThreshold": {
"value": "string"
},
"monthlySpendLimit": {
"value": "string"
},
"hourlySpendLimit": {
"value": "string"
},
"nextInvoiceTotal": {
"value": "string"
},
"creditBalance": {
"value": "string"
},
"creditBalanceRecharge": {
"low": {
"value": "string"
},
"high": {
"value": "string"
},
"autoRecharge": "boolean",
"transaction": {
"id": "string",
"amount": {
"value": "string"
},
"description": "string",
"createTime": "string",
"status": "string",
"succeeded": "boolean",
"latestCharge": {
"amount": {
"value": "string"
},
"createTime": "string",
"paid": "boolean",
"refunded": "boolean",
"status": "string",
"failureCode": "string"
},
"lastPaymentError": {
"code": "string",
"declineCode": "string"
}
}
},
"billingAddress": {
"name": "string",
"phone": "string",
"city": "string",
"line1": "string",
"line2": "string",
"state": "string",
"postalCode": "string",
"country": "string"
},
"state": "string",
"paymentTerms": "string"
}
DELETE
Delete billing account
Request
DELETE
/v1/billing-accounts/{id}curl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{}
POST
Add credit to billing account
Description for this endpoint is coming soon.
Path attributes
- Name
id
- Type
- string
- Description
- Name
amount.value
- Type
- string
- Description
- Name
paymentMethod
- Type
- string
- Description
- Name
radarSessionId
- Type
- string
- Description
Request
POST
/v1/billing-accounts/{id}/creditcurl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/credit' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"paymentIntent": {
"clientSecret": "string"
}
}
GET
List credit balance transactions on a billing account
Description for this endpoint is coming soon.
Path attributes
- Name
id
- Type
- string
- Description
- Name
pageSize
- Type
- integer
- Description
- Name
startingAfter
- Type
- string
- Description
Request
GET
/v1/billing-accounts/{id}/credit-balance-transactionscurl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/credit-balance-transactions' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"creditBalanceTransactions": [
{
"id": "string",
"amount": {
"value": "string"
},
"description": "string",
"createTime": "string"
}
],
"hasMore": "boolean"
}
GET
Get billing account details
Request
GET
/v1/billing-accounts/{id}/detailscurl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/details' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"billingAccount": {
"id": "string",
"createTime": "string",
"displayName": "string",
"stripeRef": "string",
"createBy": "string",
"monthlySpend": "string",
"hourlySpendRate": "string",
"taxIds": [
{
"id": "string",
"type": "string",
"value": "string"
}
],
"taxId": {
"id": "string",
"type": "string",
"value": "string"
},
"invoiceTime": "string",
"billingThreshold": {
"value": "string"
},
"monthlySpendLimit": {
"value": "string"
},
"hourlySpendLimit": {
"value": "string"
},
"nextInvoiceTotal": {
"value": "string"
},
"creditBalance": {
"value": "string"
},
"creditBalanceRecharge": {
"low": {
"value": "string"
},
"high": {
"value": "string"
},
"autoRecharge": "boolean",
"transaction": {
"id": "string",
"amount": {
"value": "string"
},
"description": "string",
"createTime": "string",
"status": "string",
"succeeded": "boolean",
"latestCharge": {
"amount": {
"value": "string"
},
"createTime": "string",
"paid": "boolean",
"refunded": "boolean",
"status": "string",
"failureCode": "string"
},
"lastPaymentError": {
"code": "string",
"declineCode": "string"
}
}
},
"billingAddress": {
"name": "string",
"phone": "string",
"city": "string",
"line1": "string",
"line2": "string",
"state": "string",
"postalCode": "string",
"country": "string"
},
"state": "string",
"paymentTerms": "string"
},
"stripeCustomer": {
"id": "string",
"name": "string",
"email": "string",
"balance": {
"value": "string"
}
}
}
GET
Get payment methods
Request
GET
/v1/billing-accounts/{id}/payment-methodscurl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/payment-methods' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"paymentMethods": [
{
"id": "string",
"type": "string",
"card": {
"brand": "string",
"country": "string",
"expMonth": "string",
"expYear": "string",
"fingerprint": "string",
"last4": "string"
},
"paypal": {
"payerEmail": "string",
"payerId": "string"
},
"isDefault": "boolean"
}
]
}
DELETE
Remove payment method
Description for this endpoint is coming soon.
Path attributes
- Name
id
- Type
- string
- Description
- Name
paymentMethodId
- Type
- string
- Description
Request
DELETE
/v1/billing-accounts/{id}/payment-methods/{paymentMethodId}curl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/payment-methods/{paymentMethodId}' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"id": "string",
"paymentMethodId": "string"
}
POST
Set default payment method
Description for this endpoint is coming soon.
Path attributes
- Name
id
- Type
- string
- Description
- Name
paymentMethodId
- Type
- string
- Description
Request
POST
/v1/billing-accounts/{id}/payment-methods/{paymentMethodId}/set-defaultcurl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/payment-methods/{paymentMethodId}/set-default' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"id": "string",
"paymentMethodId": "string"
}
GET
Get setup intent
Request
GET
/v1/billing-accounts/{id}/setup-intentcurl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/setup-intent' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"id": "string",
"clientSecret": "string"
}
GET
List transactions on a billing account
Description for this endpoint is coming soon.
Path attributes
- Name
id
- Type
- string
- Description
- Name
pageSize
- Type
- integer
- Description
- Name
startingAfter
- Type
- string
- Description
Request
GET
/v1/billing-accounts/{id}/transactionscurl 'https://rest.compute.cudo.org/v1/billing-accounts/{id}/transactions' \
-H 'Authorization: bearer <YOUR-API-KEY>'\
-H 'Accept: application/json'
Response
{
"transactions": [
{
"id": "string",
"amount": {
"value": "string"
},
"description": "string",
"createTime": "string",
"status": "string",
"succeeded": "boolean",
"latestCharge": {
"amount": {
"value": "string"
},
"createTime": "string",
"paid": "boolean",
"refunded": "boolean",
"status": "string",
"failureCode": "string"
},
"lastPaymentError": {
"code": "string",
"declineCode": "string"
}
}
],
"hasMore": "boolean"
}