Skip to content

Resource WorkOfferResource

CrucifiedPain edited this page Jun 26, 2026 · 11 revisions

WorkOfferResource (client.work_offer)

Endpoints: • workOffer.getById • workOffer.getWorkOfferByCompanyId • workOffer.getWorkOffersPaginated (cursor-paginated) • workOffer.getWageStats

.collect_all()

Fetch all items across all pages concurrently using parallel time-slicing.

Signature

await client.workoffer.collect_all(**kwargs: 'typing.Any') -> 'list[WorkOffer]'

Parameters

Name Type Default
kwargs Any *Required*

Return Models

WorkOffer

Field Type Required Description
_id string Optional
__v integer Optional
companyId string Optional The company id.
regionId string Optional The region id.
salary number Optional The salary.
energy number Optional The energy.
production number Optional The production.
citizenship string Optional The citizenship.
positions integer Optional The positions.
filled integer Optional The filled.
createdAt string Optional The timestamp when this record was created.

.get()

Get a single work offer by ID.

Signature

await client.workoffer.get(work_offer_id: 'str') -> 'WorkOffer'

Parameters

Name Type Default
work_offer_id str *Required*

Return Models

WorkOffer

Field Type Required Description
_id string Optional
__v integer Optional
companyId string Optional The company id.
regionId string Optional The region id.
salary number Optional The salary.
energy number Optional The energy.
production number Optional The production.
citizenship string Optional The citizenship.
positions integer Optional The positions.
filled integer Optional The filled.
createdAt string Optional The timestamp when this record was created.

.get_by_company()

Get all work offers posted by a specific company.

Signature

await client.workoffer.get_by_company(company_id: 'str') -> 'list[WorkOffer]'

Parameters

Name Type Default
company_id str *Required*

Return Models

WorkOffer

Field Type Required Description
_id string Optional
__v integer Optional
companyId string Optional The company id.
regionId string Optional The region id.
salary number Optional The salary.
energy number Optional The energy.
production number Optional The production.
citizenship string Optional The citizenship.
positions integer Optional The positions.
filled integer Optional The filled.
createdAt string Optional The timestamp when this record was created.

.get_paginated()

Get work offers with optional filters (cursor-paginated).

Args: energy: Filter: offers requiring at most this energy. production: Filter: offers with at least this production value. level: Filter: offers requiring at most this user level. citizenship: Filter: offers open to this citizenship.

Signature

await client.workoffer.get_paginated(*, limit: 'int' = 10, cursor: 'str | None' = None, user_id: 'str | None' = None, region_id: 'str | None' = None, energy: 'float | None' = None, production: 'float | None' = None, level: 'float | None' = None, citizenship: 'str | None' = None, auto_items: 'bool' = False, max_pages: 'int | float' = inf, cursor_end: 'str | None' = None) -> 'CursorPage[WorkOffer] | AsyncIterator[WorkOffer]'

Parameters

Name Type Default
limit int 10
cursor str None
user_id str None
region_id str None
energy float None
production float None
level float None
citizenship str None
auto_items bool False
max_pages int | float inf
cursor_end str None

Return Models

CursorPage[WorkOffer]

Field Type Required Description
_id string Optional
__v integer Optional
items array[WorkOffer] Required
nextCursor string Optional
hasMore boolean Optional

WorkOffer

Field Type Required Description
_id string Optional
__v integer Optional
companyId string Optional The company id.
regionId string Optional The region id.
salary number Optional The salary.
energy number Optional The energy.
production number Optional The production.
citizenship string Optional The citizenship.
positions integer Optional The positions.
filled integer Optional The filled.
createdAt string Optional The timestamp when this record was created.

.get_wage_stats()

Get wage statistics for a given worker profile — the range of allowed wages, the top market offer, and the best offers this worker is eligible for.

Args: energy: The worker's energy stat. production: The worker's production stat. citizenship: The worker's citizenship country ID or code.

Returns: A :class:WageStats object.

Signature

await client.workoffer.get_wage_stats(*, energy: 'float', production: 'float', citizenship: 'str') -> 'WageStats'

Parameters

Name Type Default
energy float *Required*
production float *Required*
citizenship str *Required*

.invalidate_cache()

Clear the SWR cache for all resources.

Signature

await client.workoffer.invalidate_cache() -> 'None'

Clone this wiki locally