Skip to content
OpenTrain AIOpenTrain AIOpenTrain AIDocs

Ask OpenTrain

Answers from the documentation, with sources.

What would you like to do with OpenTrain?

AI answers can be mistaken. Check the linked sources. Don’t include private account information.

Open app

DEVELOPER DOCUMENTATION

List Contracts

List your contracts (hired AI trainers) with milestones, optionally filtered by job or status.

GET/api/public/v1/contracts

Lists the contracts on your account — one per hired AI trainer per job — newest first, each with its milestone timeline. Contracts are created by hiring from a proposal. The AI trainer’s identity stays masked: first name + last initial, country, and profile path (never a full last name or an email — see privacy).

Refunded and cancelled milestones are excluded from the milestone timeline, mirroring the in-app contract view. For the post-hire conversation ID, read a single contract with GET /contracts/{id}.

Requirements: payments:read scope. Works pre-claim.

jobIdstringquery

Only return contracts on this job. Must be a job you own or can access (403 otherwise; 404 if the job doesn’t exist).

statusstringquery

Filter by contract status: active or ended. Omit to list both.

contractsobject[]
contract entry
idstring

Contract ID — use with GET /contracts/{id}, POST /contracts/{id}/milestones, and POST /contracts/{id}/end.

statusstring

active or ended.

titlestring | null

Contract display title.

jobIdstring | null

The job this contract belongs to.

proposalIdstring | null

The proposal the hire came from.

paymentTypestring | null

Payment model: FIXED_PRICE, PAY_PER_HOUR, or PAY_PER_LABEL.

rateUsdnumber | null

Contract rate in USD (per hour / per label for per-unit contracts; total for fixed-price).

estimatedTotalUsdnumber | null

Estimated total contract value in USD.

estimatedVolumenumber | null

Estimated unit volume for per-unit contracts.

hasActiveMilestoneboolean

true when the contract currently has a funded, in-progress milestone.

startDatestring | null

ISO contract start timestamp.

endDatestring | null

ISO contract end timestamp, null while active.

createdAtstring

ISO creation timestamp.

updatedAtstring

ISO last-change timestamp.

freelancerobject

The hired AI trainer: {userId, displayName, country, profilePath}. displayName is masked to first name + last initial ("Maria G."); full last names and emails are never included.

milestonesobject[]

Milestone timeline, ordered by milestone number.

milestone entry
idstring

Milestone ID — use with POST /milestones/{id}/fund and POST /milestones/{id}/approve.

namestring | null

Short milestone name.

descriptionstring | null

Work to deliver.

statusstring | null

NOT_FUNDED, ACTIVE_FUNDED, or COMPLETED.

amountUsdnumber | null

Milestone amount in USD.

volumenumber | null

Unit volume for per-unit milestones.

milestoneNumbernumber | null

Position in the contract’s milestone sequence.

dueDatestring | null

ISO due date.

pendingApprovalboolean

true when the AI trainer has submitted work and the milestone awaits your approval.

needsReviewboolean

true when the milestone is flagged for review.

invoiceIdstring | null

Linked invoice once funded/paid.

createdAtstring

ISO creation timestamp.

StatuscodeMeaning
400BAD_REQUESTstatus is not active or ended (details: {field: "status"})
401UNAUTHORIZEDMissing or invalid token
403FORBIDDENMissing payments:read scope, or jobId belongs to another account
404NOT_FOUNDjobId does not exist