Vai al contenuto
REST API · v2

VocationsAPI Docs

Dati su aziende, posizioni di lavoro e contatti per Italia e Spagna.

URL base
https://vocations.io/api/v2

Autenticazione

Ogni endpoint /v2 richiede una chiave API, inclusi quelli gratuiti. Gli endpoint /playground no.

Inviala nell'header Authorization:

Authorization: Bearer vo_5tg•••••••••••••••8ux

Tipi condivisi

? dopo qualsiasi chiave di un tipo implica che il valore è opzionale.
[] dopo qualsiasi tipo implica che il valore, se passato, deve essere un array.
Gli ID sono lunghi 16 caratteri.
Gli endpoint di ricerca accettano page (in base zero, default 0) e pageSize (minimo 1, massimo 128, default 10).
Gli array dei filtri accettano fino a 64 elementi, tranne names, cities, provinces, regions, nations, postalCodes, italy.ivas, italy.ateco, spain.cifNifs e spain.cnae, che ne accettano fino a 256. Gli endpoint batch accettano da 1 a 128 ID. Superare un limite restituisce 400.
Ogni risposta autenticata restituisce X-RateLimit-Limit, X-RateLimit-Remaining e X-RateLimit-Reset per la finestra del minuto corrente. Un 429 restituisce anche Retry-After.

type ErrorResponse = { message: string };

type CountryKey = "italy" | "spain";

type LocationLevel = {
  level: 4 | 6 | 8;
  value: string;
};

type LocationFilter = {
  country: CountryKey;
  levels: LocationLevel[];
};

type Location = {
  city?: string;
  province?: string;
  region?: string;
  nation?: string;
  latitude?: number;
  longitude?: number;
};

type PendingStatus =
  | "idle"
  | "pending"
  | "completed"
  | "notAvailable"
  | "failed";

type NumericRange =
  | { min: number; max: number }
  | { min: number; max?: undefined }
  | { min?: undefined; max: number };

type YearlySalaryRange = {
  min?: number;
  max?: number;
  currency: string;
};

type YearlyValue = {
  year: number;
  value: number;
};

type SortType =
  | "default"
  | "name"
  | "city"
  | "province"
  | "region"
  | "sectors"
  | "currentTotalRevenue"
  | "currentEmployees"
  | "currentOpenPositions";

type SortOrder = "asc" | "desc";

type PositionSource = "vocations" | "linkedIn" | "indeed" | "infoJobs";

type Hours = "full" | "part" | "shift";

type CompanyStatus = "open" | "bankruptcy" | "liquidation";

type ValueTrend = "increasing" | "decreasing" | "stable";

type ExperienceLevel = "0" | "0-1" | "1-3" | "3-5" | "5-10" | "10+";

type Contract =
  | "temporary"
  | "internship"
  | "permanent"
  | "contract"
  | "apprenticeship"
  | "freelance";

type Collar = "blue" | "white";

type SmartWorking = "yes" | "no" | "hybrid";

type BusinessUnit =
  | "finance"
  | "hr"
  | "purchasing"
  | "marketing"
  | "sales"
  | "customerService"
  | "research"
  | "operations"
  | "it"
  | "legal"
  | "strategy"
  | "sustainability"
  | "administration";

type SectorKey =
  | "administrationAccounting"
  | "textileClothing"
  | "mediaCommunicationMarketing"
  | "aeronauticsNavalDefense"
  | "realEstate"
  | "agriculture"
  | "horeca"
  | "food"
  | "artHistoryArchitecture"
  | "furniture"
  | "craftsmanship"
  | "insurance"
  | "socialCooperativesAssociations"
  | "automotive"
  | "banking"
  | "biomedical"
  | "broadcastingMusicFilm"
  | "outsourcingBusinessServices"
  | "retail"
  | "manufacturingIndustrial"
  | "chemical"
  | "energyOilGas"
  | "trade"
  | "consultingITConsulting"
  | "consumerGoods"
  | "pharmaceutical"
  | "environmentSustainabilityEcology"
  | "publishing"
  | "educationTraining"
  | "electronicsElectrotechnics"
  | "industrialEngineeringServices"
  | "sportsCultureEntertainment"
  | "publicEntitiesNonProfitPublicAdmin"
  | "financeFinancialServices"
  | "gamingBetting"
  | "rubberPlastic"
  | "largeScaleRetail"
  | "healthHygiene"
  | "humanResources"
  | "warehousePackaging"
  | "cybersecurityIT"
  | "legalCompliance"
  | "logistics"
  | "transportShipping"
  | "medical"
  | "metallurgyMechanics"
  | "exhibitionsFairsEvents"
  | "motors"
  | "cleaning"
  | "securitySurveillance"
  | "personalServices"
  | "professionalFirm"
  | "telecommunications"
  | "tourismTravel"
  | "designFashion"
  | "multiservices"
  | "technologyScienceData"
  | "automation"
  | "other";

type ItalyLegalForm =
  | "AA"
  | "AC"
  | "AE"
  | "AF"
  | "AI"
  | "AL"
  | "AM"
  | "AN"
  | "AP"
  | "AR"
  | "AS"
  | "AT"
  | "AU"
  | "AZ"
  | "CC"
  | "CE"
  | "CF"
  | "CI"
  | "CL"
  | "CM"
  | "CN"
  | "CO"
  | "CR"
  | "CS"
  | "CZ"
  | "DI"
  | "EC"
  | "ED"
  | "EE"
  | "EI"
  | "EL"
  | "EM"
  | "EN"
  | "EP"
  | "ER"
  | "ES"
  | "FI"
  | "FO"
  | "GE"
  | "IC"
  | "ID"
  | "IF"
  | "IR"
  | "LL"
  | "MA"
  | "OC"
  | "OO"
  | "OS"
  | "PA"
  | "PC"
  | "PF"
  | "PS"
  | "RC"
  | "RR"
  | "RS"
  | "SA"
  | "SC"
  | "SD"
  | "SE"
  | "SF"
  | "SG"
  | "SI"
  | "SL"
  | "SM"
  | "SN"
  | "SO"
  | "SP"
  | "SR"
  | "SS"
  | "ST"
  | "SU"
  | "SV"
  | "SZ";

type SpainLegalForm =
  | "GE"
  | "IE"
  | "IU"
  | "PO"
  | "AC"
  | "CJ"
  | "CB"
  | "CD"
  | "BI"
  | "PH"
  | "CG"
  | "CL"
  | "EX"
  | "PV"
  | "NL"
  | "NR"
  | "PJ"
  | "FN"
  | "FJ"
  | "FD"
  | "MT"
  | "MU"
  | "OA"
  | "PP"
  | "AG"
  | "SM"
  | "SA"
  | "ES"
  | "SD"
  | "SE"
  | "SB"
  | "SF"
  | "SU"
  | "CV"
  | "CP"
  | "CO"
  | "CA"
  | "CS"
  | "SC"
  | "SG"
  | "GR"
  | "LD"
  | "SL"
  | "LL"
  | "LP"
  | "NE"
  | "LF"
  | "LU"
  | "UC"
  | "UT"
  | "OR";

Playground

Stessi endpoint della v2, con dati sintetici italiani e spagnoli. Non serve alcuna chiave API.

Nessuna chiave API richiesta
Aziende
Posizioni
Contatti
Utilizzo
POSThttps://vocations.io/api/playground/companies
curl -X POST https://vocations.io/api/playground/companies \
  -H "Content-Type: application/json" \
  -d '{
    "page": 0,
    "company": {
      "locations": [{ "country": "spain", "levels": [{ "level": 4, "value": "Cataluña" }] }],
      "sectors": ["technologyScienceData"],
      "employees": [{ "min": 11, "max": 200 }]
    },
    "sortType": "name",
    "sortOrder": "asc",
    "withPositions": true
  }'
Risposta200 OK
{
  "companyIDs": [
    "pc0000000000000f",
    "pc0000000000001j",
    "pc0000000000002b"
  ],
  "totalPages": 22,
  "totalResults": 217
}
Arricchimento aziende

POSThttps://vocations.io/api/v2/companies/enrich

1 credito/azienda · 2 crediti con dati finanziari

Richiesta

type V2CompanyEnrichRequest = {
  companyIDs: string[];
};

Risposta 200

type V2EnrichedCompany = {
  companyID: string;
  parentHolding?: string;
  name: string;

  workAgency: boolean;
  openPositionCount: number;

  url?: string;
  imageFile?: string;
  linkedInURL?: string;
  indeedURL?: string;
  infoJobsURL?: string;

  address?: string;
  location?: LocationLevel[];
  nation?: string;

  sectors: SectorKey[];

  employees: YearlyValue[];

  totalRevenue: YearlyValue[];
  employeesCost: YearlyValue[];
  netProfit: YearlyValue[];

  italy?: {
    ragioneSociale: string;
    iva?: string;
    ateco?: string;
    atecoCode?: string;
    rea?: string;
    shareCapital?: number;
    legalForm?: ItalyLegalForm;
    chamberOfCommerce?: string;
  };

  spain?: {
    razonSocial: string;
    cifNif?: string;
    cnae?: string;
    cnaeCode?: string;
    legalForm?: SpainLegalForm;
    shareCapital?: number;
  };

  createdAt?: number;
  validationKey: string;
};

type V2CompanyEnrichResult = {
  companies: V2EnrichedCompany[];
  notFoundCompanyIDs: string[];
  insufficientCreditsCompanyIDs: string[];
};

imageFile contiene solo il nome del file. Per accedere al logo usa la CDN: https://cdn.vocations.io/logos/<imageFile>

notFoundCompanyIDs elenca gli ID inesistenti o non visibili alla tua chiave. insufficientCreditsCompanyIDs elenca le aziende esistenti escluse perché i crediti sono terminati durante il batch: richiedile di nuovo quando hai crediti. Un 402 viene restituito solo quando nessuna azienda richiesta era coperta dai crediti.

Possibili errori

400
Richiesta non valida
JSON o payload non valido.
401
Non autorizzato
Chiave API mancante o non valida.
429
Rate limit superato
500
Errore interno del server
Stato aziende

POSThttps://vocations.io/api/v2/companies/status

GratisRate limit: 60/min · 3600/ora

Verifica se i dati che hai già sono ancora aggiornati. Invia ogni companyID insieme alla validationKey restituita da /companies/enrich.

Richiesta

type V2CompanyStatusRequest = {
  companies: {
    companyID: string;
    validationKey: string;
  }[];
};

Esempio body

{
  "companies": [
    {
      "companyID": "cmp1a2b3c4d5e6f7g",
      "validationKey": "eyJhbGciOiJIUzI1NiJ9..."
    },
    {
      "companyID": "cmp8h9i0j1k2l3m4n",
      "validationKey": "eyJhbGciOiJIUzI1NiJ9..."
    }
  ]
}

Risposta 200

type V2CompanyStatusResult = {
  upToDateIDs: string[];
  outdatedIDs: string[];
  invalidIDs: string[];
};

outdatedIDs contiene le aziende i cui dati sono cambiati dopo l'emissione della validationKey: vanno rifatte con enrich. invalidIDs contiene aziende sconosciute, o chiavi che non appartengono al companyID con cui sono state inviate.

Possibili errori

400
Richiesta non valida
JSON o payload non valido.
401
Non autorizzato
Chiave API mancante o non valida.
429
Rate limit superato
500
Errore interno del server
Arricchimento posizioni

POSThttps://vocations.io/api/v2/positions/enrich

1 credito ogni 5 posizioni

Richiesta

type V2PositionEnrichRequest = {
  positionIDs: string[];
};

Risposta 200

type V2PositionCompanyContext = {
  companyID: string;
  workAgency: boolean;
  italy?: { ragioneSociale: string; iva?: string };
  spain?: { razonSocial: string; cifNif?: string };
};

type V2EnrichedPosition = {
  positionID: string;

  companyContext: V2PositionCompanyContext;

  name: string;
  description: string;

  urls: string[];
  sources: PositionSource[];

  targets: string[];

  cities: string[];
  provinces: string[];
  regions: string[];

  sites: Location[];

  skills: string[];
  benefits: string[];
  languages: string[];
  certifications: string[];
  courses: string[];

  experience?: ExperienceLevel;
  contract?: Contract;
  hours?: Hours;
  smartWorking: SmartWorking;
  collar?: Collar;
  protectedCategories?: boolean;

  yearlySalaryRange?: YearlySalaryRange;

  createdAt: number;
  republishedAt?: number;

  companyName?: string;

  validationKey: string;
};

type V2PositionEnrichResult = {
  positions: V2EnrichedPosition[];
  failedPositionIDs: string[];
};

companyContext è un riepilogo. Per i dati completi dell'azienda, chiama /companies/enrich.

Possibili errori

400
Richiesta non valida
JSON o payload non valido.
401
Non autorizzato
Chiave API mancante o non valida.
402
Crediti insufficienti
429
Rate limit superato
500
Errore interno del server
Verifica posizioni

POSThttps://vocations.io/api/v2/positions/check

GratisRate limit: 60/min · 3600/ora

Indica quali posizioni sono ancora aperte.

Richiesta

type V2PositionsCheckRequest = {
  positionIDs: string[];
};

Risposta 200

type V2PositionCheckResult = {
  openIDs: string[];
  closedIDs: string[];
  invalidIDs: string[];
};

Possibili errori

400
Richiesta non valida
JSON o payload non valido.
401
Non autorizzato
Chiave API mancante o non valida.
429
Rate limit superato
500
Errore interno del server
Arricchimento contatti

POSThttps://vocations.io/api/v2/contacts/enrich

3 crediti · +2 crediti con numero di telefonoRate limit: 20/min · 600/ora

Richiesta

type V2ContactEnrichRequest = {
  contactID: string;
  enrichPhoneNumber?: boolean;
};

Risposta 200

type V2EnrichedContact = {
  contactID: string;

  firstName?: string;
  lastName?: string;

  jobTitle?: string;
  headline?: string;

  linkedInURL?: string;
  photoURL?: string;

  departments: string[];

  email?: string;
  emailStatus?: PendingStatus;

  mobilePhone?: string;
  phoneStatus?: PendingStatus;

  location: LocationLevel[];

  validationKey: string;
};

Possibili errori

400
Richiesta non valida
JSON o payload non valido.
401
Non autorizzato
Chiave API mancante o non valida.
402
Crediti insufficienti
404
Contact not found
429
Rate limit superato
500
Errore interno del server
Aggiornamento contatti

POSThttps://vocations.io/api/v2/contacts/poll

2 crediti quando arriva un numeroRate limit: 20/min · 600/ora

Usalo quando /contacts/enrich ha restituito phoneStatus: "pending". Il numero compare qui una volta trovato.

Richiesta

type V2ContactPollRequest = {
  contactID: string;
};

Risposta 200

type V2ContactPollResult = {
  email?: string;
  emailStatus?: PendingStatus;

  mobilePhone?: string;
  phoneStatus: PendingStatus;
};

Le ricerche del numero che terminano con notAvailable o failed sono gratuite.

Possibili errori

400
Richiesta non valida
JSON o payload non valido.
401
Non autorizzato
Chiave API mancante o non valida.
402
Crediti insufficienti
404
Contact not found
Restituito anche per i contatti mai arricchiti.
429
Rate limit superato
500
Errore interno del server

Utilizzo

GratisRate limit: 10/min · 300/ora

Crediti utilizzati e rimanenti per la tua chiave API.

GEThttps://vocations.io/api/v2/usage

Risposta 200

type V2UsageSnapshot = {
  usedCredits: number;
  maxCredits: number;

  areCreditsShared: boolean;
  lastResetAt: number;
};

Possibili errori

401
Non autorizzato
Chiave API mancante o non valida.
429
Rate limit superato
500
Errore interno del server