### GET Request for Match Stages (Ruby) Source: https://developers.manatal.com/reference/match-stages Provides a Ruby example for retrieving match stages via a GET request. It utilizes the 'httparty' gem to send the request with appropriate headers. The code includes error handling for the request. Make sure 'httparty' is installed and replace 'YOUR_API_TOKEN' with your actual token. ```Ruby require 'httparty' url = 'https://api.manatal.com/open/v3/match-stages/' headers = { 'Authorization' => 'Token YOUR_API_TOKEN', 'accept' => 'application/json' } response = HTTParty.get(url, headers: headers) if response.success? puts response.parsed_response else puts "Error: #{response.code} - #{response.message}" end ``` -------------------------------- ### GET Request for Match Stages (cURL) Source: https://developers.manatal.com/reference/match-stages Demonstrates how to make a GET request to the /match-stages/ endpoint using cURL. This example includes setting the Authorization token and specifying the 'application/json' accept header. It requires an API token for authentication. ```Shell curl --request GET \ --url https://api.manatal.com/open/v3/match-stages/ \ --header 'Authorization: Token ' \ --header 'accept: application/json' ``` -------------------------------- ### GET Request for Match Stages (Node.js) Source: https://developers.manatal.com/reference/match-stages Illustrates how to fetch match stages using Node.js with the 'axios' library. This snippet shows setting up the request headers, including authorization, and handling the response. Ensure 'axios' is installed and an API token is provided. ```JavaScript const axios = require('axios'); const options = { method: 'GET', url: 'https://api.manatal.com/open/v3/match-stages/', headers: { 'Authorization': 'Token ', 'accept': 'application/json' } }; axios.request(options).then(function (response) { console.log(response.data); }).catch(function (error) { console.error(error); }); ``` -------------------------------- ### GET Request for Match Stages (Python) Source: https://developers.manatal.com/reference/match-stages A Python script demonstrating how to retrieve match stages using the 'requests' library. It sets up the GET request with the required authorization and accept headers. This code requires the 'requests' library to be installed and a valid API token. ```Python import requests url = "https://api.manatal.com/open/v3/match-stages/" headers = { "Authorization": "Token YOUR_API_TOKEN", "accept": "application/json" } response = requests.get(url, headers=headers) if response.status_code == 200: print(response.json()) else: print(f"Error: {response.status_code} - {response.text}") ``` -------------------------------- ### GET /candidates/{candidate_pk}/resume/ Source: https://developers.manatal.com/reference/candidates_resume_list Retrieves the resume for a specific candidate. The resume is automatically converted to PDF if it is not already in that format. ```APIDOC ## GET /candidates/{candidate_pk}/resume/ ### Description Retrieves the resume for a specific candidate. The resume is automatically converted to PDF if it is not already in that format. ### Method GET ### Endpoint /candidates/{candidate_pk}/resume/ ### Parameters #### Path Parameters - **candidate_pk** (string) - Required - The primary key of the candidate whose resume is to be retrieved. ### Response #### Success Response (200) - **id** (integer) - Readonly - The ID of the resume entry. - **resume_file** (string) - The URL of the resume file. Supported formats include PDF, DOC, DOCX, and RTF. - **created_at** (string) - Readonly - The timestamp when the resume entry was created. #### Response Example ```json [ { "id": 123, "resume_file": "https://api.manatal.com/path/to/resume.pdf", "created_at": "2023-10-27T10:00:00Z" } ] ``` ``` -------------------------------- ### POST /candidates/{candidate_pk}/resume/ Source: https://developers.manatal.com/reference/candidates_resume_create Uploads a resume for a specific candidate. The resume file can be of type pdf, doc, docx, or rtf. ```APIDOC ## POST /candidates/{candidate_pk}/resume/ ### Description Uploads a resume for a specific candidate. The resume file can be of type pdf, doc, docx, or rtf. ### Method POST ### Endpoint /candidates/{candidate_pk}/resume/ ### Parameters #### Path Parameters - **candidate_pk** (string) - Required - The primary key of the candidate. #### Request Body - **resume_file** (string) - Required - URL leading to the resume file. It can be of type pdf, doc, docx or rtf. ### Request Example ```json { "resume_file": "https://example.com/path/to/your/resume.pdf" } ``` ### Response #### Success Response (201) - **id** (integer) - ReadOnly - The unique identifier for the resume entry. - **resume_file** (string) - The URL of the uploaded resume file. - **created_at** (string) - The date and time when the resume was created. #### Response Example ```json { "id": 123, "resume_file": "https://api.manatal.com/open/v3/media/candidate/resume/example.pdf", "created_at": "2023-10-27T10:00:00Z" } ``` ``` -------------------------------- ### Get Languages List (PHP) Source: https://developers.manatal.com/reference/languages This snippet provides a PHP example for fetching the list of supported languages from the Manatal API. It uses cURL to make a GET request to the /languages/ endpoint, setting the necessary authorization and accept headers. The example illustrates how to execute the cURL request and retrieve the response body. ```php ``` -------------------------------- ### GET /candidates/{candidate_pk}/experiences/ Source: https://developers.manatal.com/reference/candidates_experiences_list Retrieves a list of work experiences for a specified candidate. ```APIDOC ## GET /candidates/{candidate_pk}/experiences/ ### Description A viewset for viewing and editing experiences of a candidate. ### Method GET ### Endpoint /candidates/{candidate_pk}/experiences/ ### Parameters #### Path Parameters - **candidate_pk** (string) - Required - The primary key of the candidate. ### Response #### Success Response (200) - **id** (integer) - ReadOnly - The unique identifier for the experience. - **position** (string) - Required - The job title or position held. - **employer** (string) - Required - The name of the company where the experience took place. - **is_current_employer** (boolean) - Whether this is the candidate's current employment. - **started_at** (string) - The date the candidate started this job (format: YYYY-MM-DD). - **ended_at** (string) - The date the candidate ended this job (format: YYYY-MM-DD). - **description** (string) - A detailed description of the job responsibilities and achievements. - **location** (string) - The geographical location of the job. - **created_at** (string) - ReadOnly - The timestamp when the experience record was created (format: YYYY-MM-DDTHH:MM:SS). #### Response Example ```json [ { "id": 123, "position": "Software Engineer", "employer": "Tech Solutions Inc.", "is_current_employer": false, "started_at": "2018-06-01", "ended_at": "2022-12-31", "description": "Developed and maintained web applications using React and Node.js.", "location": "San Francisco, CA", "created_at": "2023-01-15T10:30:00" } ] ``` ``` -------------------------------- ### Get Languages List (Python) Source: https://developers.manatal.com/reference/languages This snippet shows how to get the list of languages supported by Manatal using Python. It utilizes the 'requests' library to perform a GET request to the /languages/ endpoint, including the API token in the headers. The example demonstrates how to send the request and parse the JSON response. ```python import requests url = "https://api.manatal.com/open/v3/languages/" headers = { "Authorization": "Token YOUR_API_TOKEN", "accept": "application/json" } response = requests.get(url, headers=headers) if response.status_code == 200: print(response.json()) elif response.status_code == 401: print("Error: Unauthorized. Check your API token.") else: print(f"Error: {response.status_code}") print(response.text) ``` -------------------------------- ### List Industries - Node.js Example Source: https://developers.manatal.com/reference/industries Example of how to fetch industries using Node.js. This code snippet demonstrates making a GET request to the Manatal API's /industries/ endpoint and handling the JSON response. ```javascript const url = 'https://api.manatal.com/open/v3/industries/' const headers = new Headers({ 'Authorization': 'Token YOUR_API_TOKEN', 'accept': 'application/json' }) fetch(url, { method: 'GET', headers: headers }) .then(response => response.json()) .then(data => console.log(data)) .catch(error => console.error('Error:', error)); ``` -------------------------------- ### POST /matches/ Source: https://developers.manatal.com/reference/matches_create Creates a new match. Note that the `stage` parameter is deprecated and will be replaced by `job_pipeline_stage` in the next version. ```APIDOC ## POST /matches/ ### Description Creates a new match. The `stage` parameter is deprecated and will be replaced by `job_pipeline_stage` in the next version. ### Method POST ### Endpoint /matches/ ### Parameters #### Query Parameters - **stage** (string) - Optional - The stage of the match (deprecated). - **job_pipeline_stage** (string) - Optional - The job pipeline stage for the match. ### Request Example ```json { "example": "{}\n \"stage\": \"initial\",\n \"job_pipeline_stage\": \"screening\"\n}" } ``` ### Response #### Success Response (200) - **message** (string) - Confirmation message of match creation. #### Response Example ```json { "example": { "message": "Match created successfully." } } ``` ``` -------------------------------- ### POST /matches/ Source: https://developers.manatal.com/reference/matches_create Create a new match between a job and a candidate. ```APIDOC ## POST /matches/ ### Description Create a new match. This endpoint allows you to associate a candidate with a specific job, optionally defining the stage and other relevant dates. ### Method POST ### Endpoint /matches/ ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **job** (integer) - Required - The ID of the job the candidate is matched with. - **candidate** (integer) - Required - The ID of the candidate who has a match with the job. - **external_id** (string, optional) - The ID of the match in the API consumer systems. Max length 255. - **owner** (integer, optional) - The ID of the owner of the match. - **stage** (object, optional) - The stage of the match. Requires an 'id' (integer). - **stage.id** (integer) - Required - The ID of the match stage. - **is_active** (boolean, optional) - Whether the match is still active or not. - **hired_at** (string, optional) - Date at which the candidate was hired (format: date-time). - **submitted_at** (string, optional) - Date at which the candidate was added to the job (format: date-time). - **interview_at** (string, optional) - Date at which the candidate was last interviewed (format: date-time). - **offer_at** (string, optional) - Date at which an offer was made to the candidate (format: date-time). - **dropped_at** (string, optional) - Date at which the candidate was no longer considered for the job (format: date-time). ### Request Example ```json { "job": 123, "candidate": 456, "external_id": "ext-match-789", "owner": 78, "stage": { "id": 1 }, "is_active": true, "hired_at": "2023-10-27T10:00:00Z" } ``` ### Response #### Success Response (201 Created) - **id** (integer) - Readonly - The unique identifier for the created match. - **external_id** (string, nullable) - Id of the match in the API consumer systems. - **owner** (integer) - Owner of the match. - **organization** (integer) - Readonly - Organization that owns the job. - **job** (integer) - Job the candidate is matched with. - **candidate** (integer) - Candidate that has a match with a job. - **creator** (integer) - Readonly - User who added the candidate to the job. - **stage** (object) - Stage of the match. - **id** (integer) - The ID of the stage. - **name** (string, readonly) - The name of the stage. - **is_active** (boolean) - Whether the match is still active or not. - **hired_at** (string, nullable, format: date-time) - Date at which the candidate was hired. - **submitted_at** (string, nullable, format: date-time) - Date at which the candidate was added to the job. - **interview_at** (string, nullable, format: date-time) - Date at which the candidate was last interviewed. - **offer_at** (string, nullable, format: date-time) - Date at which an offer was made to the candidate. - **dropped_at** (string, nullable, format: date-time) - Date at which the candidate was no longer considered for the job. - **created_at** (string, readonly, format: date-time) - Timestamp when the match was created. - **updated_at** (string, readonly, format: date-time) - Timestamp when the match was last updated. #### Response Example ```json { "id": 99, "external_id": "ext-match-789", "owner": 78, "organization": 10, "job": 123, "candidate": 456, "creator": 1, "stage": { "id": 1, "name": "Applied" }, "is_active": true, "hired_at": null, "submitted_at": "2023-10-27T09:30:00Z", "interview_at": null, "offer_at": null, "dropped_at": null, "created_at": "2023-10-27T09:30:00Z", "updated_at": "2023-10-27T09:30:00Z" } ``` ``` -------------------------------- ### Get Nationalities List (Node.js) Source: https://developers.manatal.com/reference/nationalities Node.js example to fetch the list of nationalities from the Manatal API. It demonstrates making a GET request with necessary headers. The 'search' and 'ordering' query parameters can be appended to the URL for filtering results. ```javascript const https = require('https'); const options = { method: 'GET', hostname: 'api.manatal.com', port: null, path: '/open/v3/nationalities/', headers: { 'Authorization': 'Token ', 'accept': 'application/json' } }; const req = https.request(options, function (res) { const chunks = []; res.on('data', function (chunk) { chunks.push(chunk); }); res.on('end', function () { const body = Buffer.concat(chunks).toString(); console.log(body); }); }); req.end(); ``` -------------------------------- ### GET /candidates/ Source: https://developers.manatal.com/reference/candidates_list Retrieves a list of all candidates. The candidates are returned in alphabetical order. ```APIDOC ## GET /candidates/ ### Description Retrieves all candidates, ordered alphabetically. ### Method GET ### Endpoint /candidates/ ### Parameters #### Path Parameters None #### Query Parameters None ### Request Example None (GET request) ### Response #### Success Response (200) - **candidates** (array) - A list of candidate objects, each containing candidate details. #### Response Example ```json { "candidates": [ { "id": "candidate_123", "name": "Alice Smith", "email": "alice.smith@example.com" }, { "id": "candidate_456", "name": "Bob Johnson", "email": "bob.johnson@example.com" } ] } ``` ``` -------------------------------- ### GET /candidates/ Source: https://developers.manatal.com/reference/candidates_list Retrieve a list of all candidates, with options for filtering and sorting. ```APIDOC ## GET /candidates/ ### Description Retrieve all candidates ordered alphabetically. ### Method GET ### Endpoint /candidates/ ### Parameters #### Query Parameters - **id** (integer) - Optional - - **full_name** (string) - Optional - - **creator_id** (integer) - Optional - - **owner_id** (integer) - Optional - - **source_type** (string) - Optional - - **email** (string) - Optional - - **phone_number** (string) - Optional - - **gender** (string) - Optional - - **birth_date__gte** (string) - Optional - - **birth_date__lte** (string) - Optional - - **address** (string) - Optional - - **latest_degree** (string) - Optional - - **latest_university** (string) - Optional - - **current_company** (string) - Optional - - **current_position** (string) - Optional - - **description** (string) - Optional - - **external_id** (string) - Optional - - **candidate_tags** (string) - Optional - - **candidate_industries** (string) - Optional - - **candidate_location** (string) - Optional - - **created_at__gte** (string) - Optional - - **created_at__lte** (string) - Optional - ### Request Example ```json { "example": "request body" } ``` ### Response #### Success Response (200) - **field1** (type) - Description #### Response Example ```json { "example": "response body" } ``` ``` -------------------------------- ### POST /candidates/ Source: https://developers.manatal.com/reference/candidates_create Create a new candidate in the Manatal system. This endpoint allows for the creation of candidate profiles with various details including contact information, source, and consent status. ```APIDOC ## POST /candidates/ ### Description Create a new candidate. ### Method POST ### Endpoint /candidates/ ### Parameters #### Request Body - **external_id** (string) - Optional - Id of the candidate in the API consumer systems - **full_name** (string) - Required - Full name of the candidate - **owner** (integer) - Optional - ID of the owner of the candidate - default to creator if none is provided - **source_type** (string) - Optional - Origin of the candidate. Enum: "sourced", "applied", "referred", "agency", "other" - **source_other** (string) - Optional - Field to add manual information to the source if the source_type is other - **consent** (boolean) - Optional - Whether the candidate gave permission to use his data - **email** (string) - Optional - Candidate email - **phone_number** (string) - Optional - Candidate phone number - **gender** (string) - Optional - Gender of the candidate. Enum: "male", "female", "other", "unknown" - **birth_date** (string) - Optional - Candidate birth date (format: date) ### Request Example ```json { "full_name": "John Doe", "email": "john.doe@example.com", "phone_number": "123-456-7890", "source_type": "applied", "consent": true } ``` ### Response #### Success Response (201) - **id** (integer) - The unique identifier for the created candidate. - **external_id** (string) - The external ID of the candidate. - **full_name** (string) - The full name of the candidate. - **creator** (integer) - The user ID of the candidate's creator. - **owner** (integer) - The user ID of the candidate's owner. - **source_type** (string) - The origin of the candidate. - **source_other** (string) - Additional information if source_type is 'other'. - **consent** (boolean) - Indicates if the candidate gave consent. - **consent_date** (string) - The date and time consent was given (format: date-time). - **picture** (string) - A URI to the candidate's picture. - **email** (string) - The candidate's email address. - **resume** (string) - A URI to the candidate's resume. - **phone_number** (string) - The candidate's phone number. - **gender** (string) - The gender of the candidate. - **birth_date** (string) - The birth date of the candidate (format: date). #### Response Example ```json { "id": 1, "external_id": null, "full_name": "John Doe", "creator": 101, "owner": 101, "source_type": "applied", "source_other": null, "consent": true, "consent_date": "2023-10-27T10:00:00Z", "picture": "https://example.com/pictures/1.jpg", "email": "john.doe@example.com", "resume": "https://example.com/resumes/1.pdf", "phone_number": "123-456-7890", "gender": "male", "birth_date": "1990-05-15" } ``` ``` -------------------------------- ### Get Languages List (Ruby) Source: https://developers.manatal.com/reference/languages This snippet demonstrates how to retrieve the list of languages supported by Manatal using Ruby. It employs the 'httparty' gem to send a GET request to the /languages/ endpoint, including the required authorization token in the headers. The example shows how to access the JSON response data. ```ruby require 'httparty' url = 'https://api.manatal.com/open/v3/languages/' headers = { 'Authorization' => 'Token YOUR_API_TOKEN', 'accept' => 'application/json' } response = HTTParty.get(url, headers: headers) puts response.body ``` -------------------------------- ### Get Languages List (Node.js) Source: https://developers.manatal.com/reference/languages This snippet shows how to fetch the list of supported languages from the Manatal API using Node.js. It utilizes the 'node-fetch' library to make a GET request to the /languages/ endpoint, including authorization headers. The example outlines the process of sending the request and handling the JSON response. ```javascript const fetch = require('node-fetch'); const getLanguages = async () => { const response = await fetch('https://api.manatal.com/open/v3/languages/', { method: 'GET', headers: { 'Authorization': 'Token YOUR_API_TOKEN', 'accept': 'application/json' } }); const data = await response.json(); console.log(data); }; getLanguages(); ``` -------------------------------- ### Retrieve Contacts (Node.js) Source: https://developers.manatal.com/reference/contacts-1 Example of how to fetch contacts using Node.js. This code demonstrates making a GET request to the contacts API endpoint, including necessary headers. ```JavaScript const fetch = require('node-fetch'); const url = 'https://api.manatal.com/open/v3/contacts/'; const token = 'YOUR_API_TOKEN'; fetch(url, { method: 'GET', headers: { 'Authorization': `Token ${token}`, 'accept': 'application/json' } }) .then(response => response.json()) .then(data => console.log(data)) .catch(error => console.error('Error:', error)); ``` -------------------------------- ### Get Languages List (cURL) Source: https://developers.manatal.com/reference/languages This snippet demonstrates how to make a GET request to the Manatal API's /languages/ endpoint using cURL. It includes the necessary URL, headers for authorization and content type, and illustrates the basic structure of an API call to retrieve language data. No specific response details are provided in this example. ```shell curl --request GET \ --url https://api.manatal.com/open/v3/languages/ \ --header 'Authorization: Token ' \ --header 'accept: application/json' ``` -------------------------------- ### Retrieve Contacts (PHP) Source: https://developers.manatal.com/reference/contacts-1 Example of retrieving contacts using PHP. This code uses cURL to send a GET request to the Manatal API, including the necessary authentication and content type headers. ```PHP ``` -------------------------------- ### POST /candidates/{candidate_pk}/experiences/ Source: https://developers.manatal.com/reference/candidates_experiences_create Adds a new work experience to a candidate's profile. This endpoint allows you to create a new experience entry, specifying details such as position, employer, and dates. ```APIDOC ## POST /candidates/{candidate_pk}/experiences/ ### Description Adds a new work experience to a candidate's profile. ### Method POST ### Endpoint /candidates/{candidate_pk}/experiences/ ### Parameters #### Path Parameters - **candidate_pk** (integer) - Required - The primary key of the candidate. #### Query Parameters None #### Request Body - **position** (string) - Required - Name of the position. - **employer** (string) - Required - Name of the company the candidate was working for. - **is_current_employer** (boolean) - Optional - Whether it is the current job of the candidate or not. - **started_at** (string) - Optional - Date at which the candidate started the job (format: YYYY-MM-DD). - **ended_at** (string) - Optional - Date at which the candidate left the job (format: YYYY-MM-DD). - **description** (string) - Optional - Description of the job. - **location** (string) - Optional - Location of the office. ### Request Example ```json { "position": "Software Engineer", "employer": "Tech Solutions Inc.", "is_current_employer": false, "started_at": "2020-01-15", "ended_at": "2023-05-20", "description": "Developed and maintained web applications.", "location": "San Francisco" } ``` ### Response #### Success Response (201) - **id** (integer) - The unique identifier for the experience. - **position** (string) - Name of the position. - **employer** (string) - Name of the company the candidate was working for. - **is_current_employer** (boolean) - Whether it is the current job of the candidate or not. - **started_at** (string) - Date at which the candidate started the job. - **ended_at** (string) - Date at which the candidate left the job. - **description** (string) - Description of the job. - **location** (string) - Location of the office. - **created_at** (string) - Date at which the experience was added. #### Response Example ```json { "id": 123, "position": "Software Engineer", "employer": "Tech Solutions Inc.", "is_current_employer": false, "started_at": "2020-01-15", "ended_at": "2023-05-20", "description": "Developed and maintained web applications.", "location": "San Francisco", "created_at": "2023-07-20T10:30:00Z" } ``` ``` -------------------------------- ### List Industries - Ruby Example Source: https://developers.manatal.com/reference/industries This Ruby code snippet demonstrates how to retrieve a list of industries from the Manatal API. It utilizes the 'httparty' gem to make the GET request and includes the necessary headers for authentication and content type. ```ruby require 'httparty' url = 'https://api.manatal.com/open/v3/industries/' headers = { 'Authorization' => 'Token YOUR_API_TOKEN', 'accept' => 'application/json' } response = HTTParty.get(url, headers: headers) puts response.body ``` -------------------------------- ### GET /candidates/{candidate_pk}/matches/ Source: https://developers.manatal.com/reference/candidates_matches_list Retrieve all matches for a specific candidate, ordered alphabetically. Supports pagination. ```APIDOC ## GET /candidates/{candidate_pk}/matches/ ### Description Retrieve all matches ordered alphabetically. This endpoint supports pagination using `page` and `page_size` query parameters. ### Method GET ### Endpoint `/candidates/{candidate_pk}/matches/` ### Parameters #### Path Parameters - **candidate_pk** (integer) - Required - The primary key of the candidate. #### Query Parameters - **page** (integer) - Optional - A page number within the paginated result set. - **page_size** (integer) - Optional - Number of results to return per page. ### Response #### Success Response (200) - **count** (integer) - The total number of matches. - **next** (string) - URI for the next page of results, or null. - **previous** (string) - URI for the previous page of results, or null. - **results** (array) - A list of match objects. - **id** (integer) - The ID of the match. - **external_id** (string) - Id of the match in the API consumer systems. - **owner** (integer) - Owner of the match. - **organization** (integer) - Organization that owns the job. - **job** (integer) - Job the candidate is matched with. - **candidate** (integer) - Candidate that has a match with a job. - **creator** (integer) - User who added the candidate to the job. - **stage** (object) - Stage of the match. - **id** (integer) - The ID of the stage. - **name** (string) - The name of the stage. - **is_active** (boolean) - Whether the match is still active or not. - **hired_at** (string) - The date the candidate was hired. #### Response Example ```json { "count": 1, "next": null, "previous": null, "results": [ { "id": 1, "external_id": null, "owner": 1, "organization": 1, "job": 1, "candidate": 1, "creator": 1, "stage": { "id": 1, "name": "Applied" }, "is_active": true, "hired_at": null } ] } ``` ``` -------------------------------- ### Retrieve All Candidates (PHP) Source: https://developers.manatal.com/reference/candidates-1 This PHP snippet demonstrates fetching candidate data from the Manatal API using cURL. It configures a GET request with the appropriate 'Authorization' and 'accept' headers. This basic example retrieves all available candidates. ```php "https://api.manatal.com/open/v3/candidates/", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", CURLOPT_HTTPHEADER => [ "Authorization: Token ", "accept: application/json" ], ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #" . $err; } else { echo $response; } ``` -------------------------------- ### Define Candidate Experience API Endpoint (OpenAPI) Source: https://developers.manatal.com/reference/candidates_experiences_create This snippet defines the OpenAPI specification for creating a candidate's work experience. It details the request body schema, including required fields like 'position' and 'employer', and optional fields such as dates and description. The response schema is also outlined, confirming the creation of the experience. ```json { "openapi": "3.0.0", "info": { "title": "Manatal Open API", "description": "Manatal Open API documentation and API reference", "version": "v3" }, "security": [ { "api_key": [] } ], "paths": { "/candidates/{candidate_pk}/experiences/": { "post": { "operationId": "candidates_experiences_create", "description": "A viewset for viewing and editing experiences of a candidate.", "requestBody": { "content": { "application/json": { "schema": { "required": [ "position", "employer" ], "type": "object", "properties": { "id": { "title": "ID", "type": "integer", "readOnly": true }, "position": { "title": "Position", "description": "Name of the position", "type": "string", "minLength": 1 }, "employer": { "title": "Employer", "description": "Name of the company the candidate was working for", "type": "string", "minLength": 1 }, "is_current_employer": { "title": "Is current employer", "description": "Whether it is the current job of the candidate or not", "type": "boolean" }, "started_at": { "title": "Started at", "description": "Date at which the candidate started the job", "type": "string", "format": "date", "nullable": true }, "ended_at": { "title": "Ended at", "description": "Date at which the candidate left the job", "type": "string", "format": "date", "nullable": true }, "description": { "title": "Description", "description": "Description of the job", "type": "string" }, "location": { "title": "Location", "description": "Location of the office", "type": "string", "minLength": 1 }, "created_at": { "title": "Created at", "description": "Date at which the experience was added", "type": "string", "format": "date-time", "readOnly": true } } } } }, "required": true }, "responses": { "201": { "description": "", "content": { "application/json": { "schema": { "required": [ "position", "employer" ], "type": "object", "properties": { "id": { "title": "ID", "type": "integer", "readOnly": true }, "position": { "title": "Position", "description": "Name of the position", "type": "string", "minLength": 1 }, "employer": { "title": "Employer", "description": "Name of the company the candidate was working for", "type": "string", "minLength": 1 }, "is_current_employer": { "title": "Is current employer", "description": "Whether it is the current job of the candidate or not", "type": "boolean" }, "started_at": { "title": "Started at", "description": "Date at which the candidate started the job", "type": "string", "format": "date", "nullable": true }, "ended_at": { "title": "Ended at", "description": "Date at which the candidate left the job", "type": "string", "format": "date", "nullable": true }, "description": { "title": "Description", "description": "Description of the job", "type": "string" } } } } } } } } } } } ``` -------------------------------- ### POST /api/users Source: https://developers.manatal.com/reference/career-page_jobs_application-form_read Creates a new user in the system. ```APIDOC ## POST /api/users ### Description Creates a new user in the system. ### Method POST ### Endpoint /api/users ### Parameters #### Request Body - **name** (string) - Required - The name of the new user. - **email** (string) - Required - The email address of the new user. - **password** (string) - Required - The password for the new user. ### Request Example ```json { "example": { "name": "Jane Smith", "email": "jane.smith@example.com", "password": "securepassword123" } } ``` ### Response #### Success Response (201) - **id** (string) - The unique identifier of the newly created user. - **message** (string) - A confirmation message. #### Response Example ```json { "example": { "id": "user456", "message": "User created successfully" } } ``` ``` -------------------------------- ### List Industries - Python Example Source: https://developers.manatal.com/reference/industries This Python code snippet shows how to make a GET request to the Manatal API's /industries/ endpoint using the 'requests' library. It includes setting the authorization token and accepting JSON in the response. ```python import requests url = 'https://api.manatal.com/open/v3/industries/' token = 'YOUR_API_TOKEN' headers = { 'Authorization': f'Token {token}', 'accept': 'application/json' } response = requests.get(url, headers=headers) if response.status_code == 200: print(response.json()) else: print(f'Error: {response.status_code}') ``` -------------------------------- ### GET /websites/developers_manatal_reference/candidates/{candidate_pk}/matches/ Source: https://developers.manatal.com/reference/candidates_matches_list Retrieves all matches for a given candidate, ordered alphabetically. Note that the 'stage' parameter is deprecated in favor of 'job_pipeline_stage'. ```APIDOC ## GET /candidates/{candidate_pk}/matches/ ### Description Retrieve all matches ordered alphabetically. ### Method GET ### Endpoint /candidates/{candidate_pk}/matches/ ### Parameters #### Path Parameters - **candidate_pk** (integer) - Required - The primary key of the candidate. #### Query Parameters - **stage** (string) - Optional - The stage of the job pipeline (deprecated, use `job_pipeline_stage`). - **job_pipeline_stage** (string) - Optional - The job pipeline stage. ### Request Example (No request body for GET requests) ### Response #### Success Response (200) - **matches** (array) - A list of matches. - **match_id** (integer) - The ID of the match. - **candidate_id** (integer) - The ID of the candidate. - **job_id** (integer) - The ID of the job. - **stage** (string) - The stage of the match. - **created_at** (string) - The timestamp when the match was created. #### Response Example ```json { "matches": [ { "match_id": 123, "candidate_id": 456, "job_id": 789, "stage": "interview", "created_at": "2023-10-27T10:00:00Z" } ] } ``` ``` -------------------------------- ### Retrieve All Candidates (Python) Source: https://developers.manatal.com/reference/candidates-1 This Python snippet uses the 'requests' library to make a GET request to the Manatal API for retrieving candidate information. It includes the 'Authorization' and 'accept' headers. This example fetches all candidates without applying any filters. ```python import requests url = "https://api.manatal.com/open/v3/candidates/" headers = { "Authorization": "Token ", "accept": "application/json" } response = requests.get(url, headers=headers) print(response.json()) ``` -------------------------------- ### GET /matches/ Source: https://developers.manatal.com/reference/matches_list Retrieve a list of all matches, with options for ordering and filtering. ```APIDOC ## GET /matches/ ### Description Retrieve a list of all matches. The results can be ordered alphabetically and filtered by various criteria. ### Method GET ### Endpoint /matches/ ### Parameters #### Query Parameters - **ordering** (string) - Optional - Which field to use when ordering the results. - **external_id** (string) - Optional - Filter by external ID. - **stage__in** (string) - Optional - Filter by stage. Multiple values may be separated by commas. - **hired_at__gte** (string) - Optional - Filter matches hired on or after a specific date. - **hired_at__lte** (string) - Optional - Filter matches hired on or before a specific date. - **submitted_at__gte** (string) - Optional - Filter matches submitted on or after a specific date. - **submitted_at__lte** (string) - Optional - Filter matches submitted on or before a specific date. - **interview_at__gte** (string) - Optional - Filter matches interviewed on or after a specific date. - **interview_at__lte** (string) - Optional - Filter matches interviewed on or before a specific date. - **offer_at__gte** (string) - Optional - Filter matches with offers on or after a specific date. - **offer_at__lte** (string) - Optional - Filter matches with offers on or before a specific date. - **dropped_at__gte** (string) - Optional - Filter matches dropped on or after a specific date. - **dropped_at__lte** (string) - Optional - Filter matches dropped on or before a specific date. - **created_at__gte** (string) - Optional - Filter matches created on or after a specific date. - **created_at__lte** (string) - Optional - Filter matches created on or before a specific date. - **updated_at__gte** (string) - Optional - Filter matches updated on or after a specific date. - **updated_at__lte** (string) - Optional - Filter matches updated on or before a specific date. - **page** (integer) - Optional - A page number within the paginated result set. - **page_size** (integer) - Optional - Number of results to return per page. ### Request Example ```json { "example": "GET /matches/?ordering=external_id&page_size=20" } ``` ### Response #### Success Response (200) - **match_id** (integer) - The unique identifier for the match. - **candidate_id** (integer) - The ID of the candidate in the match. - **job_id** (integer) - The ID of the job in the match. - **stage** (string) - The current stage of the match. - **hired_at** (string) - The date and time when the candidate was hired. - **submitted_at** (string) - The date and time when the candidate was submitted. - **interview_at** (string) - The date and time of the interview. - **offer_at** (string) - The date and time the offer was made. - **dropped_at** (string) - The date and time the match was dropped. - **created_at** (string) - The date and time the match was created. - **updated_at** (string) - The date and time the match was last updated. #### Response Example ```json { "example": "{\n \"count\": 100,\n \"next\": \"/api/matches/?page=2\",\n \"previous\": null,\n \"results\": [\n {\n \"match_id\": 1,\n \"candidate_id\": 101,\n \"job_id\": 201,\n \"stage\": \"interview\",\n \"hired_at\": \"2023-01-15T10:00:00Z\",\n \"submitted_at\": \"2023-01-10T09:00:00Z\",\n \"interview_at\": \"2023-01-12T14:30:00Z\",\n \"offer_at\": null,\n \"dropped_at\": null,\n \"created_at\": \"2023-01-05T11:00:00Z\",\n \"updated_at\": \"2023-01-15T10:00:00Z\"\n }\n // ... more matches\n ]\n}" } ``` ``` -------------------------------- ### Retrieve All Candidates (Node.js) Source: https://developers.manatal.com/reference/candidates-1 This Node.js snippet shows how to fetch candidate data using the 'node-fetch' library. It constructs a GET request to the Manatal API, including an 'Authorization' header. This is a basic example for retrieving all candidates without specific filters. ```javascript const fetch = require('node-fetch'); const options = { method: 'GET', headers: { 'Authorization': 'Token ', 'accept': 'application/json' } }; fetch('https://api.manatal.com/open/v3/candidates/', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err)); ```