Skip to content

Retrieve the latest invoice for a User

GEThttps://api.neuroscale.io/v2.0/users/{user-id}/invoices/latest

Path parameters

Name Type Description
user-id String Unique identifier of the User or self.

The Invoice resource has the following attributes:

Name Type Description
consumable_hours Object / Hash Defines the total number of consumable hours available to the User during the period of the Invoice as well as the amount of hours used and the amount of hours remaining.
instances Object / Hash Defines the total number of instances created by the User during the period of the Invoice as well as the number of instances currently running and the number of instances that have been terminated.
period Object / Hash Defines the period of the Invoice (date and time) as a pair of start and end Unix timestamps.

Authentication

Type: Access token
Required scopes: user or read:user

Responses

Example response — 200

{
    "consumable_hours": {
        "used": 200.42,
        "remaining": 549.58,
        "total": 750
    },
    "instances": {
        "running": 5,
        "terminated": 12,
        "total": 17
    },
    "period": {
        "start": 1443657600,
        "end": 1446335999
    }
}