Skip to main content

Python SDK for OmegaHire vacancy integration API

Project description

omegavacancy-sdk

Python SDK для интеграционного API OmegaHire (/api/v1/vacancies).

Подробная инструкция публикации в TestPyPI/PyPI: PUBLISHING_RU.md.

Install

pip install -e .

Usage

from omegavacancy_sdk import OmegaVacancyClient

api_key = "ovk_xxxxx_secret"

with OmegaVacancyClient(base_url="https://your-host", api_key=api_key) as client:
    created = client.create_vacancy({
        "title": "Python Developer",
        "vacancy_text": "Need FastAPI + PostgreSQL",
        "skills": ["Python", "FastAPI"],
    })
    print(created.vacancy_ids)

    for vacancy_id in created.vacancy_ids:
        deleted = client.delete_vacancy(vacancy_id)
        print(deleted.success, deleted.vacancy_id)

Errors

  • OmegaVacancyAuthError — 401/403
  • OmegaVacancyValidationError — 422
  • OmegaVacancyServerError — 5xx/transport
  • OmegaVacancyError — прочие ошибки

Какие методы доступны сейчас

OmegaVacancyClient

  • create_vacancy(vacancy: dict) -> CreateVacancyResult
  • create_vacancies(vacancies: list[dict]) -> CreateVacancyResult
  • delete_vacancy(vacancy_id: str) -> DeleteVacancyResult
  • close() -> None

Контекстный менеджер:

  • __enter__() / __exit__(...)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

omegavacancy_sdk-0.1.0.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

omegavacancy_sdk-0.1.0-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

Details for the file omegavacancy_sdk-0.1.0.tar.gz.

File metadata

  • Download URL: omegavacancy_sdk-0.1.0.tar.gz
  • Upload date:
  • Size: 6.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for omegavacancy_sdk-0.1.0.tar.gz
Algorithm Hash digest
SHA256 3c913973ccdd5bf8ca4959d7baaff0c7dc5253bf9d8f954cccff138a3622e1bd
MD5 9fe8bb481c7fcd42a2596442d64713f5
BLAKE2b-256 54f4f239715dca8d3c4016da10f8fdc2595659748993700e61649a498c6eb119

See more details on using hashes here.

File details

Details for the file omegavacancy_sdk-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for omegavacancy_sdk-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8c072e1ede97c5156baa13302268994caaee6b39e4aa8b61936571a39724abdb
MD5 545bd66071f60a42a67e01d24a6f9480
BLAKE2b-256 10e2fe59322e9e633196da86766cd9806db732a492ce7d3afc9d3693dd547621

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page