API
GuidesGet API token
Admin Resources

Accounts

This resource allows a caller to inspect basic information regarding the staff accounts in the store.
How Accounts relate to other resources

#The account object

An Account record represents a staff account details for the Store. One Store can have many staff's account.

Attributes

  • idinteger
    Unique numeric identifier for the Account.
  • user_idinteger
    The unique numeric identifier of the user associated to the Account.
    There can only be one Account per user per Store.
  • created_atdatetime
    The date and time when the Account was created.
  • invited_atdatetime
    The date and time the user was last invited to open their Account
    null for the store creator.
    If an invite to open an Account is re-issued for a user, invited_at will hold the timestamp of the most recent invite sent.
  • is_ownerboolean
    Flags whether this user is the store owner.
    A Store can have multiple owners.
The account object
{
  "account": {
    "id": 3315125,
    "user_id": 2057785,
    "created_at": "2021-07-20T09:10:19+00:00",
    "invited_at": "2021-07-18T09:10:19+00:00",
    "is_owner": false
  }
}

#Retrieve an account

GET/accounts/{id}
Retrieves an account for the store.
Scoperead_accounts
GET/accounts/{id}
curl 'https://api.rechargeapps.com/accounts/331512' \
  -H 'X-Recharge-Version: 2021-11' \
  -H 'X-Recharge-Access-Token: your_api_token'
Response
{
  "account": {
    "id": 3315125,
    "user_id": 2057785,
    "created_at": "2021-07-20T09:10:19+00:00",
    "invited_at": "2021-07-18T09:10:19+00:00",
    "is_owner": false
  }
}

#List accounts

GET/accounts
Returns all accounts associated to the store.
Scoperead_accounts
GET/accounts
curl 'https://api.rechargeapps.com/accounts?limit=3' \
  -H 'X-Recharge-Version: 2021-11' \
  -H 'X-Recharge-Access-Token: your_api_token'
Response
{
  "accounts": [
    {
      "id": 3315125,
      "user_id": 2057785,
      "created_at": "2021-07-20T09:10:19+00:00",
      "invited_at": "2021-07-18T09:10:19+00:00",
      "is_owner": false
    },
    {
      "id": 3316125,
      "user_id": 2056785,
      "created_at": "2021-05-20T09:10:19+00:00",
      "invited_at": null,
      "is_owner": true
    }
  ]
}