HydraCore
API by router

Staff

Query Staff Internal

Query staff with qualification filters. Auth: Bearer proxy key.

GET
/internal/v1/instances/{instance_id}/staff

Path Parameters

instance_idInstance Id
Formatuuid

Query Parameters

customer_idCustomer Id
Formatuuid
skills?Skills

Comma-separated skills to filter by

induction_site?Induction Site

Site induction required

cert_type?Cert Type

Certification type required (checks expiry)

status?Status
tier?Tier
page?Page
Default1
Range1 <= value
per_page?Per Page
Default50
Range1 <= value <= 200

Response Body

curl -X GET "https://loading/internal/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff?customer_id=497f6eca-6276-4993-bfeb-53cbbbba6f08&skills=string&induction_site=string&cert_type=string&status=string&tier=1&page=1&per_page=50"
{
  "page": 0,
  "per_page": 0,
  "staff": [
    {
      "availability_notes": "string",
      "certifications": [],
      "created_at": "2019-08-24T14:15:22Z",
      "customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",
      "email": "string",
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "inductions": [],
      "name": "string",
      "phone": "string",
      "role": "string",
      "skills": [],
      "status": "string",
      "tenant_id": "34f5c98e-f430-457b-a812-92637d0c6fd0",
      "tier": 0,
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ],
  "total": 0
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Create Staff Internal

Create a staff record. Auth: Bearer proxy key.

POST
/internal/v1/instances/{instance_id}/staff

Path Parameters

instance_idInstance Id
Formatuuid

Query Parameters

customer_idCustomer Id
Formatuuid
availability_notes?Availability Notes
certifications?Certifications
email?Email
inductions?Inductions
nameName
Lengthlength <= 200
phone?Phone
role?Role

One of: ('employee', 'contractor', 'supplier', 'customer_contact')

Default"employee"
skills?Skills
tier?Tier
Default1
Range1 <= value <= 5

Response Body

curl -X POST "https://loading/internal/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff?customer_id=497f6eca-6276-4993-bfeb-53cbbbba6f08" \  -H "Content-Type: application/json" \  -d '{    "name": "string"  }'
{
  "availability_notes": "string",
  "certifications": [],
  "created_at": "2019-08-24T14:15:22Z",
  "customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",
  "email": "string",
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "inductions": [],
  "name": "string",
  "phone": "string",
  "role": "string",
  "skills": [],
  "status": "string",
  "tenant_id": "34f5c98e-f430-457b-a812-92637d0c6fd0",
  "tier": 0,
  "updated_at": "2019-08-24T14:15:22Z"
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Expiring Certs Internal

List staff with certs expiring within N days. Auth: Bearer proxy key.

GET
/internal/v1/instances/{instance_id}/staff/expiring-certs

Path Parameters

instance_idInstance Id
Formatuuid

Query Parameters

customer_idCustomer Id
Formatuuid
within_days?Within Days
Default42
Range1 <= value <= 365

Response Body

curl -X GET "https://loading/internal/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff/expiring-certs?customer_id=497f6eca-6276-4993-bfeb-53cbbbba6f08&within_days=42"
null
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Import Staff Internal

Bulk import staff. Auth: Bearer proxy key.

POST
/internal/v1/instances/{instance_id}/staff/import

Path Parameters

instance_idInstance Id
Formatuuid

Query Parameters

customer_idCustomer Id
Formatuuid
staffStaff
Itemsitems <= 200

Response Body

curl -X POST "https://loading/internal/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff/import?customer_id=497f6eca-6276-4993-bfeb-53cbbbba6f08" \  -H "Content-Type: application/json" \  -d '{    "staff": [      {        "name": "string"      }    ]  }'
{
  "created": 0,
  "errors": []
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Get Staff Internal

Get a single staff member. Auth: Bearer proxy key.

GET
/internal/v1/instances/{instance_id}/staff/{person_id}

Path Parameters

instance_idInstance Id
Formatuuid
person_idPerson Id
Formatuuid

Response Body

curl -X GET "https://loading/internal/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff/497f6eca-6276-4993-bfeb-53cbbbba6f08"
{
  "availability_notes": "string",
  "certifications": [],
  "created_at": "2019-08-24T14:15:22Z",
  "customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",
  "email": "string",
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "inductions": [],
  "name": "string",
  "phone": "string",
  "role": "string",
  "skills": [],
  "status": "string",
  "tenant_id": "34f5c98e-f430-457b-a812-92637d0c6fd0",
  "tier": 0,
  "updated_at": "2019-08-24T14:15:22Z"
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Update Staff Internal

Update a staff member. Auth: Bearer proxy key.

PATCH
/internal/v1/instances/{instance_id}/staff/{person_id}

Path Parameters

instance_idInstance Id
Formatuuid
person_idPerson Id
Formatuuid
availability_notes?Availability Notes
certifications?Certifications
email?Email
inductions?Inductions
name?Name
phone?Phone
role?Role
skills?Skills
status?Status
tier?Tier

Response Body

curl -X PATCH "https://loading/internal/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff/497f6eca-6276-4993-bfeb-53cbbbba6f08" \  -H "Content-Type: application/json" \  -d '{}'
{
  "availability_notes": "string",
  "certifications": [],
  "created_at": "2019-08-24T14:15:22Z",
  "customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",
  "email": "string",
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "inductions": [],
  "name": "string",
  "phone": "string",
  "role": "string",
  "skills": [],
  "status": "string",
  "tenant_id": "34f5c98e-f430-457b-a812-92637d0c6fd0",
  "tier": 0,
  "updated_at": "2019-08-24T14:15:22Z"
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

List Staff Dashboard

List staff for tenant dashboard. Auth: JWT (admin only).

GET
/v1/customers/{customer_id}/staff
AuthorizationBearer <token>

In: header

Path Parameters

customer_idCustomer Id
Formatuuid

Query Parameters

skills?Skills
status?Status
page?Page
Default1
Range1 <= value
per_page?Per Page
Default50
Range1 <= value <= 200

Header Parameters

X-Api-Key?X-Api-Key

Response Body

curl -X GET "https://loading/v1/customers/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff?skills=string&status=string&page=1&per_page=50" \  -H "X-Api-Key: string"
{
  "page": 0,
  "per_page": 0,
  "staff": [
    {
      "availability_notes": "string",
      "certifications": [],
      "created_at": "2019-08-24T14:15:22Z",
      "customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",
      "email": "string",
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "inductions": [],
      "name": "string",
      "phone": "string",
      "role": "string",
      "skills": [],
      "status": "string",
      "tenant_id": "34f5c98e-f430-457b-a812-92637d0c6fd0",
      "tier": 0,
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ],
  "total": 0
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Bulk Import Staff

Bulk import staff for a customer. Auth: JWT (admin only).

POST
/v1/customers/{customer_id}/staff/import
AuthorizationBearer <token>

In: header

Path Parameters

customer_idCustomer Id
Formatuuid

Header Parameters

X-Api-Key?X-Api-Key
staffStaff
Itemsitems <= 200

Response Body

curl -X POST "https://loading/v1/customers/497f6eca-6276-4993-bfeb-53cbbbba6f08/staff/import" \  -H "X-Api-Key: string" \  -H "Content-Type: application/json" \  -d '{    "staff": [      {        "name": "string"      }    ]  }'
{
  "created": 0,
  "errors": []
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}