GET: /source

This endpoint allows you to retrieve a source info given a key.

get
Source

https://api.hrflow.ai/v1/source
Request
Response
Request
Headers
X-API-KEY
required
string
Authentication token
X-USER-EMAIL
required
string
User's email
Query Parameters
key
required
string
Source key
Response
200: OK
Source's info successfully retrieved.
"code": 200,
"message": "Source info",
"data": {
"id": 1166,
"key": "91456df437fbd49a566adc5e0b0b33d13b115d06",
"name": "folder demo",
"description": null,
"type": "folder",
"subtype": "folder",
"private": true,
"status": true,
"archive": null,
"members": [
],
"notification": false,
"consent": false,
"consent_url": null,
"user": {
"id": 16,
"email": "[email protected]",
"pseudo": "medbenqa",
"firstName": null,
"lastName": null,
"avatarUrl": "/images/user.png",
"locale": "english",
"position": null,
"phone": null
},
"updated_at": "2020-09-01T17:51:36+0000",
"created_at": "2020-09-01T17:51:36+0000"
}
}
400: Bad Request
Could not find a source matching this query.
{
"code": 400,
"message": "Invalid source fields"
}
401: Unauthorized
Invalid secret key or unauthorized access.
{
"code": 401,
"message": "Unauthorized. Invalid secret key: xxxxx "
}
OR
{
"code": 401,
"message": "Unauthorized Access to source key: xxxxxx"
}

Example

Bash
Python
Javascript
Bash
$curl --url "https://api.hrflow.ai/source?source_id=source_id" --header "X-API-KEY: api_key"
Python
from hrflow import Hrflow
client = Hrflow(api_secret: "Your API Key", api_user: "Your API user email")
client.source.get(key="source_key")
Javascript
// npm install --save hrflow
import Hrflow from 'hrflow';
const client = new Hrflow({
api_secret: 'Your API Key',
api_user: 'Your API user email'
});
client.source.get('source_key').then(response => {
console.log(response);
// ...
});