Saltar al contenido principal

Get Account - GET

To get a user's specific account, you need to make a GET request to the endpoint

GET https://api.palenca.com/v1/accounts/:account_id

User's can have more than one account. Make sure to use the correct account_id when making requests to this endpoint.

const axios = require('axios')

const config = {
method: 'get',
url: 'https://api.palenca.com/v1/accounts/:account_id',
headers: {
'x-api-key': 'private_api_key',
'Content-Type': 'application/json'
},
};

(() => {
try {
const { data } = await axios(config)
console.info(JSON.stringify(response.data))
} catch (error) {
console.error(error)
}
})()

Returns a JSON structured like this:

{
"success": true,
"error": null,
"data": {
"account_id": "472f02e8-6b24-43a7-b529-3f71d6ecc81c",
"country": "mx",
"platform": "uber",
"identifier": "gonzalo@palenca.com",
"worker_id": "123456",
"last_successful_connection": "2022-11-22T17:11:57.697777",
"status": "success",
"message": null,
"recommendation": null,
"status_details": null,
"warning": null
}
}

Query params

ParameterDescriptionTypeRequiredExample
account_idThe ID of the account we want to retrieveuuidTrue472f02e8-6b24-43a7-b529-3f71d6ecc81c