Skip to main content

Create a role

Create a role (job) in an organization. Scope: roles:write.

POST/api/v1/roles 🔒 API key

Creates a role (job) in a target organization. Scope: roles:write. Requires employer-write authority in organizationId (admins bypass). The role is created with its default pipeline steps and, where applicable, HR-rep assignment.

Request body

FieldTypeRequiredDescription
namestringYesRole title.
organizationIdstringYesOrganization to create the role in.
descriptionstringNoRole description.
department / location / workTypestringNoremote / hybrid / onsite for workType.
priority / roleLevel / statusstringNoMetadata.
salaryMin / salaryMax / targetHireCountintegerNoNumbers.
salaryCurrency / salaryPeriodstringNoSalary currency / period.
isPublicbooleanNoWhether the role is public.

Example request

curl -X POST https://app.talent-ray.com/api/v1/roles \
  -H "Authorization: Bearer tr_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Senior Backend Engineer", "organizationId": "org_acme", "department": "Engineering", "workType": "remote" }'

Response

201 Created — the created role (same shape as Get a role).

Status codes

StatusMeaning
201Created.
400bad_request — missing/invalid fields.
401No valid API key.
403insufficient_scope (missing roles:write) or forbidden (no write authority in the target org).
429Rate limit / usage limit exceeded.