Welcome to the new Golem Cloud Docs! 👋
Documentation
Account

Account API

The account API allows users to query and manipulate their own account data.

Get account

PathMethodProtected
/v1/accounts/{account_id}GETYes

Retrieve an account for a given Account ID

Example Response JSON

{
  "id": "string",
  "name": "string",
  "email": "string",
  "planId": "b3f60ba2-c1fd-4b3a-a23d-8e876e0ef75d"
}

Update account

PathMethodProtected
/v1/accounts/{account_id}PUTYes

Allows the user to change the account details such as name and email.

Changing the planId is not allowed and the request will be rejected. The response is the updated account data.

Example Request JSON

{
  "name": "string",
  "email": "string"
}

Example Response JSON

{
  "id": "string",
  "name": "string",
  "email": "string",
  "planId": "b3f60ba2-c1fd-4b3a-a23d-8e876e0ef75d"
}

Delete account

PathMethodProtected
/v1/accounts/{account_id}DELETEYes

Delete an account.

Example Response JSON

{}

Get account's plan

PathMethodProtected
/v1/accounts/{account_id}/planGETYes

Example Response JSON

{
  "planId": "b3f60ba2-c1fd-4b3a-a23d-8e876e0ef75d",
  "planData": {
    "projectLimit": 0,
    "componentLimit": 0,
    "workerLimit": 0,
    "storageLimit": 0,
    "monthlyGasLimit": 0,
    "monthlyUploadLimit": 0
  }
}

Create account

PathMethodProtected
/v1/accountsPOSTYes

Create a new account. The response is the created account data.

Example Request JSON

{
  "name": "string",
  "email": "string"
}

Example Response JSON

{
  "id": "string",
  "name": "string",
  "email": "string",
  "planId": "b3f60ba2-c1fd-4b3a-a23d-8e876e0ef75d"
}

Account API Errors

Status CodeDescriptionBody
400Invalid request, returning with a list of issues detected in the request{"errors":["string"]}
401Unauthorized request{"error":"string"}
404Account not found{"error":"string"}
500Internal server error{"error":"string"}