Invite operator/driver to company
Users
POST invite operator
Endpoint
POST /api/v1/users/invitation
Parameters
Name | Description |
---|---|
user[email] required | |
user[first_name] required | First name |
user[last_name] required | Last name |
user[job_position] required | Job position (admin) |
user[company_id] required | Company id (admin) |
user[contact_phone_number] required | Contact phone number |
Request
Route
POST /api/v1/users/invitation
Headers
Accept: application/json
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiIxODQyIiwic2NwIjoidXNlciIsImF1ZCI6bnVsbCwiaWF0IjoxNzU4MDEyNTEyLCJleHAiOjE3NjA2MDQ1MTIsImp0aSI6ImQ5MjFiMDY0LTFkZDEtNDA3OC04YWRiLWIwM2EzZmMzZDNiOSJ9.e3SoT5FQOn73FGwFcXRG-YcHkiP3Ik741XASZtHjAGw
Host: example.org
Cookie:
Body
{
"user": {
"email": "rudolf.jenkins@franecki-stoltenberg.test",
"first_name": "Dorathy",
"last_name": "King",
"contact_phone_number": "07732 330259"
}
}
Response
Simulated Response
Status
200
Headers
x-frame-options: SAMEORIGIN
x-xss-protection: 0
x-content-type-options: nosniff
x-permitted-cross-domain-policies: none
referrer-policy: strict-origin-when-cross-origin
content-type: application/json; charset=utf-8
vary: Accept, Origin
etag: W/"7951ebcc2be9949ed2772af6cc329d70"
cache-control: max-age=0, private, must-revalidate
x-request-id: a875100b-752a-4815-8e23-0891390cef59
x-runtime: 0.131183
content-length: 391
Body
{
"user": {
"id": 1843,
"company": {
"id": 705,
"address": "Apt. 374 218 MacGyver Loaf, Streichchester, NC AE1E 2RS",
"license_number": "8500197262",
"name": "Becker-Aufderhar",
"state": "verified"
},
"contact_phone_number": "07732 330259",
"email": "rudolf.jenkins@franecki-stoltenberg.test",
"first_name": "Dorathy",
"job_position": null,
"last_name": "King",
"phone_number": null,
"profile_id": null,
"role": "operator"
}
}