---
updatedAt: 2026-05-28T05:27:12.000Z
agentTools:
  projectIndex: https://developers.smartrecruiters.com/llms.txt
---

# Create a new candidate and assign to a Talent Pool

Create a new candidate and assign to a Talent Pool.

**Tracking candidate source**

When adding a new candidate, it's very important you track its source appropriately. In order to associate a source with your app/integration, add below object to a candidate body object for this endpoint:
```
{
  "sourceDetails": {
    "sourceTypeId": "string",
    "sourceSubTypeId": "string",
    "sourceId": "string"
  }
}
```
**sourceTypeId** - it's a Source Type - available values can be found using [get /configuration/sources](https://developers.smartrecruiters.com/reference/configurationsourcetypes-1) endpoint

**sourceSubTypeId** - it's a Source Subtype, an optional parameter - available values can be found using [get /configuration/sources](https://developers.smartrecruiters.com/reference/configurationsourcetypes-1) endpoint

**sourceId** - it's a Source Id - available values for a given sourceTypeId can be found using [get /configuration/sources/:sourceTypeId/values](https://developers.smartrecruiters.com/reference/configurationsourcevaluesall-1) endpoint

NOTE: Not defining the source will default to **API** source.

NOTE II: In case you can't find an appropriate source to track against you can:
* Create a custom source for each customer account separately on [this admin page](https://www.smartrecruiters.com/settings/configuration/custom-sources) (you need to be logged in as an admin to the customer account in order to view this page)
* Request to [partners@smartrecruiters.com](mailto:partners@smartrecruiters.com) adding a standard source that will be available for all customers if your app/integration is productised (available to all SmartRecruiters customers)


# OpenAPI definition

````json
{
  "openapi": "3.0.1",
  "info": {
    "version": "1",
    "title": "Candidates API",
    "contact": {
      "name": "SmartRecruiters",
      "url": "https://developers.smartrecruiters.com"
    }
  },
  "tags": [
    {
      "name": "candidates"
    }
  ],
  "paths": {
    "/candidates": {
      "post": {
        "responses": {
          "201": {
            "description": "Created candidate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CandidateDetails"
                }
              }
            }
          },
          "400": {
            "description": "with codes\n* **SOURCE_NOT_FOUND** when provided source does not exist,\n* **SUBTYPE_REQUIRED** when there are more sources and subtype parameter is required,\n* **INVALID_PROPERTY_VALUE** when provided property value does not conform to the domain requirements\n",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "with code **PERMISSION_DENIED** when you are not permitted to create candidate",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "with code **SOURCE_TYPE_NOT_FOUND** when provided source type does not exist\n",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "description": "Create a new candidate and assign to a Talent Pool.\n\n**Tracking candidate source**\n\nWhen adding a new candidate, it's very important you track its source appropriately. In order to associate a source with your app/integration, add below object to a candidate body object for this endpoint:\n```\n{\n  \"sourceDetails\": {\n    \"sourceTypeId\": \"string\",\n    \"sourceSubTypeId\": \"string\",\n    \"sourceId\": \"string\"\n  }\n}\n```\n**sourceTypeId** - it's a Source Type - available values can be found using [get /configuration/sources](https://developers.smartrecruiters.com/reference/configurationsourcetypes-1) endpoint\n\n**sourceSubTypeId** - it's a Source Subtype, an optional parameter - available values can be found using [get /configuration/sources](https://developers.smartrecruiters.com/reference/configurationsourcetypes-1) endpoint\n\n**sourceId** - it's a Source Id - available values for a given sourceTypeId can be found using [get /configuration/sources/:sourceTypeId/values](https://developers.smartrecruiters.com/reference/configurationsourcevaluesall-1) endpoint\n\nNOTE: Not defining the source will default to **API** source.\n\nNOTE II: In case you can't find an appropriate source to track against you can:\n* Create a custom source for each customer account separately on [this admin page](https://www.smartrecruiters.com/settings/configuration/custom-sources) (you need to be logged in as an admin to the customer account in order to view this page)\n* Request to [partners@smartrecruiters.com](mailto:partners@smartrecruiters.com) adding a standard source that will be available for all customers if your app/integration is productised (available to all SmartRecruiters customers)\n",
        "tags": [
          "candidates"
        ],
        "summary": "Create a new candidate and assign to a Talent Pool",
        "operationId": "candidates.add",
        "security": [
          {
            "key": []
          },
          {
            "oauth": [
              "candidates_create"
            ]
          }
        ],
        "requestBody": {
          "$ref": "#/components/requestBodies/CandidateInput"
        }
      }
    }
  },
  "components": {
    "requestBodies": {
      "CandidateInput": {
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/CandidateInput"
            }
          }
        },
        "description": "Candidate object that needs to be created.",
        "required": true
      }
    },
    "securitySchemes": {
      "key": {
        "type": "apiKey",
        "in": "header",
        "name": "x-smarttoken"
      },
      "oauth": {
        "type": "oauth2",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://www.smartrecruiters.com/identity/oauth/allow",
            "tokenUrl": "https://api.smartrecruiters.com/identity/oauth/token",
            "scopes": {
              "candidates_read": "Access Candidates",
              "candidates_create": "Create Candidates",
              "candidates_offers_read": "Access Offer Terms",
              "candidates_manage": "Manage Candidate Status and Properties",
              "candidate_status_read": "Access Candidate's status",
              "candidates_parse_resume": "Access Resume Parsing"
            }
          }
        }
      }
    },
    "schemas": {
      "ErrorResponse": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Error"
            }
          }
        }
      },
      "Error": {
        "type": "object",
        "required": [
          "code"
        ],
        "properties": {
          "code": {
            "type": "string"
          },
          "message": {
            "type": "string"
          }
        }
      },
      "CandidateInput": {
        "type": "object",
        "required": [
          "firstName",
          "lastName",
          "email"
        ],
        "properties": {
          "firstName": {
            "type": "string",
            "minLength": 1
          },
          "lastName": {
            "type": "string",
            "minLength": 1
          },
          "email": {
            "type": "string",
            "format": "email"
          },
          "phoneNumber": {
            "type": "string"
          },
          "location": {
            "$ref": "#/components/schemas/CandidateLocation"
          },
          "web": {
            "$ref": "#/components/schemas/WebProfile"
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "education": {
            "type": "array",
            "default": [],
            "items": {
              "$ref": "#/components/schemas/Education"
            }
          },
          "experience": {
            "type": "array",
            "default": [],
            "items": {
              "$ref": "#/components/schemas/Experience"
            }
          },
          "sourceDetails": {
            "$ref": "#/components/schemas/CandidateSource"
          },
          "internal": {
            "type": "boolean"
          }
        }
      },
      "CandidateDetails": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "internal": {
            "type": "boolean"
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "phoneNumber": {
            "type": "string"
          },
          "location": {
            "$ref": "#/components/schemas/CandidateLocation"
          },
          "web": {
            "$ref": "#/components/schemas/WebProfile"
          },
          "createdOn": {
            "type": "string",
            "format": "date-time"
          },
          "updatedOn": {
            "type": "string",
            "format": "date-time"
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "averageRating": {
            "type": "number",
            "deprecated": true
          },
          "education": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Education"
            }
          },
          "experience": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Experience"
            }
          },
          "primaryAssignment": {
            "description": "Its latest modified application from applications in non final-state. If no applications in non-final state then one in final state with most recent modification date is returned. Inactive(final) states are Lead, Rejected, Transferred, Withdrawn, Hired",
            "allOf": [
              {
                "$ref": "#/components/schemas/Job"
              },
              {
                "$ref": "#/components/schemas/Assignment"
              }
            ]
          },
          "secondaryAssignments": {
            "description": "List of assignemnts (applications). Applications are sorted by state (non-final states first) and then by date. First one is excluded and is returned as primaryAssignment. Mentioned date is a date of last modification of an application eg: changed state, change of a source, reapply, anonymisation, unshare. Inactive(final) states are Lead, Rejected, Transferred, Withdrawn, Hired",
            "type": "array",
            "items": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/Job"
                },
                {
                  "$ref": "#/components/schemas/Assignment"
                }
              ]
            }
          },
          "actions": {
            "type": "object",
            "required": [
              "properties"
            ],
            "properties": {
              "properties": {
                "$ref": "#/components/schemas/Action"
              },
              "attachments": {
                "$ref": "#/components/schemas/Action"
              },
              "consent": {
                "$ref": "#/components/schemas/Action"
              },
              "consents": {
                "$ref": "#/components/schemas/Action"
              }
            }
          }
        }
      },
      "CandidateLocation": {
        "type": "object",
        "properties": {
          "country": {
            "type": "string",
            "minLength": 1
          },
          "countryCode": {
            "type": "string",
            "minLength": 2,
            "maxLength": 2
          },
          "regionCode": {
            "type": "string"
          },
          "region": {
            "type": "string"
          },
          "city": {
            "type": "string",
            "minLength": 1
          },
          "lat": {
            "type": "number",
            "format": "float"
          },
          "lng": {
            "type": "number",
            "format": "float"
          }
        }
      },
      "CandidateStatusEnum": {
        "type": "string",
        "enum": [
          "LEAD",
          "NEW",
          "IN_REVIEW",
          "INTERVIEW",
          "OFFERED",
          "HIRED",
          "REJECTED",
          "WITHDRAWN",
          "TRANSFERRED"
        ]
      },
      "Assignment": {
        "type": "object",
        "properties": {
          "status": {
            "$ref": "#/components/schemas/CandidateStatusEnum"
          },
          "subStatus": {
            "type": "string"
          },
          "startsOn": {
            "type": "string",
            "format": "date-time"
          },
          "source": {
            "type": "string"
          },
          "reasonOfRejection": {
            "$ref": "#/components/schemas/Property"
          },
          "reasonOfWithdrawal": {
            "$ref": "#/components/schemas/Property"
          },
          "actions": {
            "type": "object",
            "properties": {
              "sourceDetails": {
                "$ref": "#/components/schemas/Action"
              }
            }
          }
        }
      },
      "Job": {
        "type": "object",
        "properties": {
          "job": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "title": {
                "type": "string"
              },
              "actions": {
                "type": "object",
                "required": [
                  "details"
                ],
                "properties": {
                  "details": {
                    "$ref": "#/components/schemas/Action"
                  },
                  "positionDetails": {
                    "$ref": "#/components/schemas/Action"
                  }
                }
              }
            }
          }
        }
      },
      "Action": {
        "type": "object",
        "required": [
          "url",
          "method"
        ],
        "properties": {
          "url": {
            "type": "string"
          },
          "method": {
            "type": "string",
            "enum": [
              "GET",
              "POST",
              "PUT",
              "PATCH",
              "OPTIONS",
              "DELETE",
              "HEAD",
              "CONNECT"
            ]
          }
        }
      },
      "WebProfile": {
        "type": "object",
        "properties": {
          "skype": {
            "type": "string"
          },
          "linkedin": {
            "type": "string"
          },
          "facebook": {
            "type": "string"
          },
          "twitter": {
            "type": "string"
          },
          "website": {
            "type": "string"
          }
        }
      },
      "Education": {
        "type": "object",
        "properties": {
          "institution": {
            "type": "string",
            "minLength": 1
          },
          "degree": {
            "type": "string",
            "minLength": 1
          },
          "major": {
            "type": "string",
            "minLength": 1
          },
          "current": {
            "type": "boolean"
          },
          "location": {
            "type": "string"
          },
          "startDate": {
            "$ref": "#/components/schemas/When"
          },
          "endDate": {
            "$ref": "#/components/schemas/When"
          },
          "description": {
            "type": "string"
          }
        }
      },
      "Experience": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string",
            "minLength": 1
          },
          "company": {
            "type": "string",
            "minLength": 1
          },
          "current": {
            "type": "boolean"
          },
          "startDate": {
            "$ref": "#/components/schemas/When"
          },
          "endDate": {
            "$ref": "#/components/schemas/When"
          },
          "location": {
            "type": "string"
          },
          "description": {
            "type": "string"
          }
        }
      },
      "CandidateSource": {
        "type": "object",
        "required": [
          "sourceTypeId",
          "sourceId"
        ],
        "properties": {
          "sourceTypeId": {
            "type": "string",
            "minLength": 1
          },
          "sourceSubTypeId": {
            "type": "string"
          },
          "sourceId": {
            "type": "string",
            "minLength": 1
          }
        }
      },
      "Property": {
        "type": "object",
        "required": [
          "id"
        ],
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1
          },
          "label": {
            "type": "string"
          }
        }
      },
      "When": {
        "type": "string",
        "format": "when",
        "description": "date in YYYY, YYYY-MM or YYYY-MM-dd format, ex. \"2016\", \"2016-11\", \"2016-11-29\""
      }
    }
  },
  "servers": [
    {
      "url": "https://api.smartrecruiters.com"
    }
  ]
}
````