Skip to content

Tutorial: Create and Submit an Inquiry

This tutorial guides you through the complete workflow for creating an inquiry, adding a position (hire) to it, and submitting it for processing in People Cloud.

Step 1: Create a Draft Inquiry

Use this endpoint to create a new inquiry with one or more position requirements. The inquiry will be saved in a "draft" state and can later be edited or submitted.

Endpoint

POST /api/public/inquiry/new

Authorization

This endpoint requires authentication. Use the Bearer token from the authenticated user session.

Request Headers

Authorization: Bearer <your_token_here>
Accept: application/json
Content-Type: application/json

Request Body Structure

Below is a detailed breakdown of the body fields:

  • title: Title of the inquiry.
  • description: Optional rich HTML description.
  • hires: An array of one or more job roles under this inquiry. Each hire contains:
    • stage: Should be "draft" for initial save.
    • title, type, budget, etc.: Define job scope and criteria.
  • industry: JSON object with a "name" field (e.g., "Software").
  • main_contact: Text describing the person responsible.

Example


{
  "title": "Full",
  "description": "<div>Nice</div>",
  "client": { "email": null },
  "email": null,
  "colleague_id": null,
  "hires": [
    {
      "stage": "draft",
      "title": "Dev",
      "type": "external",
      "order_need_reqs": [{ "name": "C#", "importance": 3 }],
      "allocation": "10",
      "budget": "5000",
      "cv_deadline": "",
      "cv_deadline_vendor": "",
      "deliverables": "",
      "description": "<div>fx</div>",
      "experience_level": "Intermediate",
      "files": [],
      "is_remote_work": "no",
      "video_required": 0,
      "is_video_required": false,
      "vendor_price": "",
      "job_end": "2025-11-30T16:00:00.000Z",
      "job_start": "2025-11-01T16:30:00.000Z",
      "language_reqs": "Fin",
      "location": "",
      "method_reqs": null,
      "tech_reqs": null,
      "project_end_at": "",
      "submitted_at": null,
      "utc_cv_deadline": ""
    }
  ],
  "industry": { "name": "Software" },
  "main_contact": "Lawunn (lawunnkhaing16@gmail.com, +358402224007)",
  "original_client": null,
  "selected_vendors": [],
  "shareToGroup": false
}

Step 2: Submit the Inquiry

Once you're ready, the draft inquiry can be published using this endpoint.

cURL Example

curl -X POST http://127.0.0.1:8000/api/public/inquiry/new \
  -H "Authorization: Bearer $TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Full",
    "description": "<div>Nice</div>",
    "client": { "email": null },
    "email": null,
    "colleague_id": null,
    "hires": [{
      "stage": "draft",
      "title": "Dev",
      "type": "external",
      "order_need_reqs": [{ "name": "C#", "importance": 3 }],
      "allocation": "10",
      "budget": "5000",
      "cv_deadline": "",
      "cv_deadline_vendor": "",
      "deliverables": "",
      "description": "<div>fx</div>",
      "experience_level": "Intermediate",
      "files": [],
      "is_remote_work": "no",
      "video_required": 0,
      "is_video_required": false,
      "vendor_price": "",
      "job_end": "2025-11-30T16:00:00.000Z",
      "job_start": "2025-11-01T16:30:00.000Z",
      "language_reqs": "Fin",
      "location": "",
      "method_reqs": null,
      "tech_reqs": null,
      "project_end_at": "",
      "submitted_at": null,
      "utc_cv_deadline": ""
    }],
    "industry": { "name": "Software" },
    "main_contact": "Lawunn (lawunnkhaing16@gmail.com, +358402224007)",
    "original_client": null,
    "selected_vendors": [],
    "shareToGroup": false
  }'

Step 4. Evaluate response

If everything goes well, you should get an HTTP response with an empty JSON object ({ }) in the response body.

Status Meaning Description
200 OK The service is up, and the API token is valid.
401 Unauthorized The API token is invalid.