Platformă de descoperire a joburilor — documentație API publică
Această pagină expune endpoint-uri publice ale API-ului peviitor.ro, o platformă de descoperire a joburilor. Suntem în proces de revizuire și extindere a API-ului, iar documentația se va îmbunătăți treptat.
Endpoint-urile de mai jos sunt disponibile în acest moment și pot fi folosite pentru testare și explorare. API-ul este în curs de standardizare, iar pentru fiecare funcționalitate vom publica treptat endpoint-uri noi, împreună cu o documentație mai detaliată.
Returns a single random job from the Solr job index. Useful for discovery widgets, "job of the day" features, or testing integrations.
curl -X GET "https://api.peviitor.ro/v1/random/" \ -H "Accept: application/json"
| Field | Type | Description |
|---|---|---|
| title | string | Exact job position title |
| company | string | Hiring company name (uppercase) |
| location | string[] | Array of cities or addresses |
| workmode | string | remote, on-site, or hybrid |
| url | string | Full URL to the job detail page (unique key) |
| salary | string | Salary interval with currency, e.g. 5000-8000 RON |
| tags | string[] | Skill tags (lowercase, max 20) |
| cif | string | CIF/CUI of the company |
| date | string | ISO8601 UTC timestamp of indexing |
| status | string | scraped, tested, published, or verified |
{
"title": "Inginer IT",
"company": "COMPANY SRL",
"location": ["Bucure\u0219ti", "Cluj-Napoca"],
"workmode": "remote",
"url": "https://example.com/job/123",
"salary": "5000-8000 RON",
"tags": ["python", "java"],
"cif": "12345678",
"date": "2026-06-15T10:00:00Z",
"status": "published"
}
{
"error": "No jobs found"
}
{
"error": "Job core unavailable",
"details": "SOLR_SERVER not set"
}
| Item | Details |
|---|---|
| Method | GET only |
| Auth | None (public endpoint) |
| Params | None |
| Content-Type | application/json |
Returns the total number of job listings and companies currently indexed in the Solr cores. Useful for dashboard counters, statistics widgets, or monitoring integrations.
job Solr core for the total number of indexed jobscompany Solr core for the total number of indexed companiescurl -X GET "https://api.peviitor.ro/v1/total/" \ -H "Accept: application/json"
| Field | Type | Description |
|---|---|---|
| total | object | Container object with count fields |
| total.jobs | number | Total number of job listings currently indexed |
| total.companies | number | Total number of companies currently indexed |
{
"total": {
"jobs": 18452,
"companies": 934
}
}
{
"error": "Only GET method allowed"
}
Triggered when Solr is unreachable, returns an invalid response, or the environment is not configured.
The details field contains the underlying error message for debugging.
{
"error": "Job core unavailable",
"details": "SOLR_SERVER not set"
}
{
"error": "Job core unavailable",
"details": "FETCH FAILED: http://... | Connection timed out"
}
{
"error": "Job core unavailable",
"details": "Invalid JSON response"
}
| Item | Details |
|---|---|
| Method | GET only |
| Auth | None (public endpoint) |
| Params | None |
| Content-Type | application/json |
Permanently deletes every job document matching the given company from the job Solr core.
Designed for company website owners who want to remove their listings from the peviitor platform.
company name, cif, or brandX-Api-Key as MD5 hash based on the provided identifiers
You must provide an X-Api-Key header computed as md5() of the identifiers you send.
The key is generated from the same fields in the request body:
| Body fields | X-Api-Key formula |
|---|---|
company + cif | md5(company + cif) (recommended) |
company only | md5(company) |
brand only | md5(brand) |
{
"company": "NUME SRL",
"cif": "12345678",
"confirmation": "CLEAN_COMPANY_JOBS"
}
At least one of company, cif, or brand is required.
The confirmation field must be exactly "CLEAN_COMPANY_JOBS".
COMPANY="NUME SRL"
CIF="12345678"
KEY=$(echo -n "${COMPANY}${CIF}" | md5sum | cut -d' ' -f1)
curl -X DELETE "https://api.peviitor.ro/v1/cleanjobs/" \
-H "X-Api-Key: $KEY" \
-H "Content-Type: application/json" \
-d '{
"company": "'"$COMPANY"'",
"cif": "'"$CIF"'",
"confirmation": "CLEAN_COMPANY_JOBS"
}'
| Field | Type | Description |
|---|---|---|
| message | string | Success confirmation message |
| jobCount | number | Number of jobs deleted |
| company | string | Company name (if provided) |
| cif | string | Company CIF (if provided) |
| brand | string | Company brand (if provided) |
{
"message": "Jobs deleted successfully",
"jobCount": 42,
"company": "NUME SRL",
"cif": "12345678"
}
{
"error": "Unauthorized - invalid X-Api-Key"
}
{
"error": "No jobs found",
"message": "No jobs found matching the given criteria"
}
{
"error": "Only DELETE method allowed"
}
{
"error": "Job core unavailable",
"details": "SOLR_SERVER not set"
}
| Item | Details |
|---|---|
| Method | DELETE only |
| Auth | X-Api-Key: md5(company + cif) (or md5(company) / md5(brand)) |
| Params | Body: {"company"?: "...", "cif"?: "...", "brand"?: "...", "confirmation": "CLEAN_COMPANY_JOBS"} |
| Content-Type | application/json |
Searches the Solr company core using edismax and returns matching company documents.
You can search by exact CIF (8-digit number) or by company name (full-text search).
cif (exact match) or name (full-text search) as a query parametercompany core| Param | Type | Description |
|---|---|---|
| cif | string | 8-digit CIF/CUI (exact match). Non-digit characters are stripped. |
| name | string | Company name for full-text search via edismax |
| rows | number | Max results to return (default: 10, max: 50) |
| start | number | Offset for pagination (default: 0) |
At least one of cif or name is required.
curl -X GET "https://api.peviitor.ro/v1/firme/company/?cif=24415960" \ -H "Accept: application/json" curl -X GET "https://api.peviitor.ro/v1/firme/company/?name=Google&rows=5" \ -H "Accept: application/json"
| Field | Type | Description |
|---|---|---|
| success | boolean | Always true on success |
| total | number | Total number of matching documents in Solr |
| count | number | Number of documents returned in this response |
| data | object[] | Array of company documents |
| data[].id | string | CIF/CUI (8 digits) |
| data[].company | string | Company legal name |
| data[].brand | string | Brand name (if set) |
| data[].group | string | Company group (if set) |
| data[].status | string | activ, suspendat, inactiv, or radiat |
| data[].location | string[] | Array of locations |
| data[].website | string[] | Array of website URLs |
| data[].career | string[] | Array of career page URLs |
| data[].lastScraped | string | ISO8601 timestamp of last scrape |
| data[].scraperFile | string | Scraper file name |
{
"success": true,
"total": 1,
"count": 1,
"data": [{
"id": "24415960",
"company": "GOOGLE ROMANIA SRL",
"brand": "Google",
"status": "activ",
"location": ["București"],
"website": ["https://google.ro"],
"career": ["https://careers.google.com"]
}]
}
{
"error": "Missing query parameter: cif or name"
}
{
"error": "Company search unavailable",
"details": "SOLR_SERVER not set"
}
| Item | Details |
|---|---|
| Method | GET only |
| Auth | None (public endpoint) |
| Params | Query: cif (string) or name (string), optional rows (int, max 50), start (int) |
| Content-Type | application/json |
Upserts a company document into the Solr company core. If a document with the same CIF (id) already exists, it is replaced.
Designed for scrapers and company integrations to keep the company index up to date.
id as 8-digit CIF, company name)htmlspecialchars to prevent XSSlocation, website, career) — accepts string or arraywebsite and career fieldscommitWithin=1000 and overwrite=true
This endpoint uses Solr Basic Auth via environment variables SOLR_USER and SOLR_PASS configured in api.env.
No client-side authentication is required.
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | Yes | 8-digit CIF/CUI (e.g. "24415960") |
| company | string | Yes | Company legal name |
| brand | string | No | Brand / trade name |
| group | string | No | Company group / parent |
| status | string | No | One of: activ, suspendat, inactiv, radiat |
| location | string|string[] | No | City or array of cities |
| website | string|string[] | No | Website URL(s) — must be valid URLs |
| career | string|string[] | No | Career page URL(s) — must be valid URLs |
| lastScraped | string | No | ISO8601 timestamp of last scrape |
| scraperFile | string | No | Name of the scraper file |
curl -X PUT "https://api.peviitor.ro/v1/firme/company/add/" \
-H "Content-Type: application/json" \
-d '{
"id": "24415960",
"company": "GOOGLE ROMANIA SRL",
"brand": "Google",
"status": "activ",
"location": ["București"],
"website": ["https://google.ro"],
"career": ["https://careers.google.com"]
}'
| Field | Type | Description |
|---|---|---|
| success | boolean | Always true on success |
| id | string | The CIF of the upserted company |
| message | string | Confirmation message |
{
"success": true,
"id": "24415960",
"message": "Company 'GOOGLE ROMANIA SRL' (24415960) upserted to company core"
}
Returned when the request body is invalid or required fields are missing/invalid.
{
"error": "Missing required fields: id, company",
"code": 400
}
{
"error": "Field 'id' must be an 8-digit CIF/CUI string (e.g. '24415960')",
"code": 400
}
{
"error": "Field 'status' must be one of: activ, suspendat, inactiv, radiat",
"code": 400
}
{
"error": "Invalid website URL: not-a-url"
}
{
"error": "Only PUT method allowed"
}
{
"error": "Company core unavailable",
"details": "FETCH FAILED: http://... | Connection timed out"
}
| Item | Details |
|---|---|
| Method | PUT only |
| Auth | Solr Basic Auth (server-side, via api.env) |
| Params | Body: {"id": "...", "company": "...", ...} |
| Content-Type | application/json |
Accepts a JSON array of job listings and upserts them directly into the Solr job core.
Designed for automated scrapers that need to upload jobs in bulk.
Automatically fixes diacritics in city names and lowercases tags.
Existing jobs (same url) are overwritten.
{"jobs": [...]})url, title, company)location (fixes diacritics, accepts string or array)tags and filters empty valuescommitWithin=1000 and overwrite=true
This endpoint uses Solr Basic Auth via environment variables SOLR_USER and SOLR_PASS configured in api.env.
No client-side authentication is required.
Accepts either a plain array [{...}, ...] or an object {"jobs": [{...}, ...]}.
| Field | Type | Required | Description |
|---|---|---|---|
| url | string | Yes | Full URL to the job detail page (unique key) |
| title | string | Yes | Exact job position title |
| company | string | Yes | Hiring company name |
| cif | string | No | CIF/CUI of the company |
| location | string|string[] | No | City or array of cities (diacritics auto-fixed) |
| tags | string[] | No | Skill tags (auto-lowercased) |
| workmode | string | No | remote, on-site, or hybrid |
| date | string | No | ISO8601 UTC timestamp |
| status | string | No | scraped, tested, published, or verified |
curl -X POST "https://api.peviitor.ro/v1/scraper/jobs/upload/" \
-H "Content-Type: application/json" \
-d '[
{
"url": "https://example.com/job/123",
"title": "Inginer IT",
"company": "COMPANY SRL",
"cif": "12345678",
"location": ["București", "Cluj-Napoca"],
"tags": ["javascript", "react"],
"workmode": "remote",
"date": "2026-07-24T10:00:00Z",
"status": "scraped"
}
]'
| Field | Type | Description |
|---|---|---|
| success | string | Confirmation message |
| count | number | Number of jobs sent to Solr |
{
"success": "Jobs successfully uploaded to Solr",
"count": 29
}
{
"error": "Payload must be a non-empty JSON array of jobs",
"code": 400
}
{
"error": "No valid jobs found in payload (url, title, company required)",
"code": 400
}
{
"error": "Only POST method is allowed",
"code": 405
}
{
"error": "Content-Type must be application/json",
"code": 415
}
{
"error": "Job core unavailable",
"details": "SOLR_SERVER not set"
}
| Item | Details |
|---|---|
| Method | POST only |
| Auth | Solr Basic Auth (server-side, via api.env) |
| Params | Body: [{"url": "...", "title": "...", "company": "...", ...}] |
| Content-Type | application/json |
Queries the Solr job core for all jobs matching a company CIF.
Returns paginated results with standard job fields.
Designed for scrapers that need to read existing jobs before re-scraping.
cif parameter (must be exactly 8 digits)job core with pagination support| Param | Type | Required | Description |
|---|---|---|---|
| cif | string | Yes | 8-digit CIF/CUI (exact match) |
| rows | number | No | Max results (default: 100, max: 500) |
| start | number | No | Offset for pagination (default: 0) |
curl -X GET "https://api.peviitor.ro/v1/scraper/jobs/?cif=24415960" \ -H "Accept: application/json" curl -X GET "https://api.peviitor.ro/v1/scraper/jobs/?cif=24415960&rows=10&start=0" \ -H "Accept: application/json"
| Field | Type | Description |
|---|---|---|
| success | boolean | Always true on success |
| total | number | Total number of matching jobs in Solr |
| count | number | Number of jobs returned in this response |
| data | object[] | Array of job documents |
{
"success": true,
"total": 32,
"count": 32,
"data": [
{
"url": "https://example.com/job/123",
"title": "Senior Developer",
"company": "COMPANY SRL",
"cif": "24415960",
"location": ["București"],
"tags": ["javascript"],
"workmode": "remote",
"date": "2026-07-26T10:00:00Z",
"status": "scraped"
}
]
}
{
"error": "Missing required query parameter: cif",
"code": 400
}
{
"error": "CIF must be exactly 8 digits",
"code": 400
}
{
"error": "Only GET method is allowed",
"code": 405
}
{
"error": "Job core unavailable",
"details": "SOLR_SERVER not set"
}
| Item | Details |
|---|---|
| Method | GET only |
| Auth | Solr Basic Auth (server-side, via api.env) |
| Params | Query: cif (string, required), optional rows (int, max 500), start (int) |
| Content-Type | application/json |
Deletes jobs from the Solr job core by company CIF (all jobs) or by URL (single job).
Designed for internal scraper use — when a company becomes inactive in ANAF or when expired job URLs are cleaned up.
cif or urlcommit=true| Field | Type | Required | Description |
|---|---|---|---|
| cif | string | Conditional | Delete all jobs for this 8-digit CIF |
| url | string | Conditional | Delete a single job by its URL |
Exactly one of cif or url is required. Providing both returns an error.
curl -X DELETE "https://api.peviitor.ro/v1/scraper/jobs/delete/" \
-H "Content-Type: application/json" \
-d '{"cif": "24415960"}'
curl -X DELETE "https://api.peviitor.ro/v1/scraper/jobs/delete/" \
-H "Content-Type: application/json" \
-d '{"url": "https://example.com/job/123"}'
| Field | Type | Description |
|---|---|---|
| success | boolean | Always true on success |
| message | string | Confirmation message |
| count | number | Number of jobs deleted |
{
"success": true,
"message": "Jobs deleted successfully",
"count": 32
}
{
"error": "Request body must be a JSON object, not an array",
"code": 400
}
{
"error": "At least one of 'cif' or 'url' is required",
"code": 400
}
{
"error": "Provide only 'cif' or 'url', not both",
"code": 400
}
{
"error": "CIF must be exactly 8 digits",
"code": 400
}
{
"error": "No jobs found",
"message": "No jobs found matching cif:24415960",
"count": 0
}
{
"error": "Only DELETE method is allowed",
"code": 405
}
{
"error": "Content-Type must be application/json",
"code": 415
}
{
"error": "Job core unavailable",
"details": "SOLR_SERVER not set"
}
| Item | Details |
|---|---|
| Method | DELETE only |
| Auth | Solr Basic Auth (server-side, via api.env) |
| Params | Body: {"cif": "..."} or {"url": "..."} |
| Content-Type | application/json |
Lucrăm la:
Pe măsură ce noile endpoint-uri vor deveni disponibile, le vom publica aici împreună cu exemple de request/response și recomandări de integrare.
Obiectivul nostru este să oferim un mod simplu și automat prin care website-urile de companii să trimită joburi către peviitor.ro prin API. Designul urmărit este:
exemplu.com)Pe măsură ce aceste componente vor fi gata, le vom documenta pe această pagină.