Import a chunk of volunteer historical hours rows
POST
/api/volunteers/import/hours/chunk
const url = 'https://example.com/api/volunteers/import/hours/chunk';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"session_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","rows":[{"row_number":1,"source_user_id":"example","first_name":"example","last_name":"example","full_name":"example","clock_in":"example","clock_out":"example","notes":"example","raw_data":{}}]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/volunteers/import/hours/chunk \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "session_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "rows": [ { "row_number": 1, "source_user_id": "example", "first_name": "example", "last_name": "example", "full_name": "example", "clock_in": "example", "clock_out": "example", "notes": "example", "raw_data": {} } ] }'Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
session_id
required
string format: uuid
rows
required
Array<object>
object
row_number
integer
source_user_id
string
first_name
string
last_name
string
full_name
string
clock_in
required
string
clock_out
string
notes
string
raw_data
object
Examplegenerated
{ "session_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "rows": [ { "row_number": 1, "source_user_id": "example", "first_name": "example", "last_name": "example", "full_name": "example", "clock_in": "example", "clock_out": "example", "notes": "example", "raw_data": {} } ]}Responses
Section titled “Responses”Hours chunk processed successfully
Media typeapplication/json
object
processed
required
integer
successful
required
integer
warnings
required
Array<object>
object
id
string format: uuid
session_id
string format: uuid
file_type
required
string
row_number
required
integer
raw_data
object
warning_code
required
string
message
required
string
created_at
string format: date-time
warnings_count
integer
stats
object
Example
{ "warnings": [ { "file_type": "roster", "row_number": 12, "warning_code": "INVALID_PHONE", "message": "Failed to normalize phone number" } ]}Bad request / Invalid input parameters
Media typeapplication/problem+json
RFC 7807 Problem Details for HTTP APIs
object
type
required
string
title
required
string
status
required
Current status of the record or process.
integer
detail
required
string
instance
string
retry_after
integer
Example
{ "status": "IN_PROGRESS", "retry_after": 60}Authentication required or invalid credentials
Media typeapplication/problem+json
RFC 7807 Problem Details for HTTP APIs
object
type
required
string
title
required
string
status
required
Current status of the record or process.
integer
detail
required
string
instance
string
retry_after
integer
Example
{ "status": "IN_PROGRESS", "retry_after": 60}Access denied / Insufficient role privileges
Media typeapplication/problem+json
RFC 7807 Problem Details for HTTP APIs
object
type
required
string
title
required
string
status
required
Current status of the record or process.
integer
detail
required
string
instance
string
retry_after
integer
Example
{ "status": "IN_PROGRESS", "retry_after": 60}Resource not found
Media typeapplication/problem+json
RFC 7807 Problem Details for HTTP APIs
object
type
required
string
title
required
string
status
required
Current status of the record or process.
integer
detail
required
string
instance
string
retry_after
integer
Example
{ "status": "IN_PROGRESS", "retry_after": 60}