Get the account
GET
/api/account
const url = 'https://app.nurseshark.org/api/account';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://app.nurseshark.org/api/account \ --header 'Authorization: Bearer <token>'Who the token belongs to. Handy for checking a token works.
Authorizations
Section titled “Authorizations”Responses
Section titled “Responses”OK
Media typeapplication/json
object
email_address
required
string format: email
projects_count
required
How many projects the account has, archived ones included.
integer
token
required
The name the token was given when it was created.
string
Example generated
{ "email_address": "hello@example.com", "projects_count": 1, "token": "example"}The token is missing, invalid or expired.
Media typeapplication/json
object
error
required
What went wrong and what to change.
string
errors
For validation failures, the messages for each field.
object
key
additional properties
Array<string>
Example generated
{ "error": "example", "errors": { "additionalProperty": [ "example" ] }}Over the rate limit. Try again in a minute.
Media typeapplication/json
object
error
required
What went wrong and what to change.
string
errors
For validation failures, the messages for each field.
object
key
additional properties
Array<string>
Example generated
{ "error": "example", "errors": { "additionalProperty": [ "example" ] }}