Use Jobs.ch Swiss Job Listings by Region & Industry with Python
Scrape job listings from jobs.ch, Switzerland's largest job board. Search by keyword or browse by canton, industry, occupational field, or contract type, with filters for workload and seniority. Returns title, company, location, and job URL.
1. Choose the data you need
Review the published README for supported collection modes, examples, and limits. The recipe below uses the current published input definition.
2. Prepare a source-based input
This JSON contains published prefills and required-field defaults. Review every value for your task before running it; it is not a promise of successful collection.
{
"categories": [],
"companyIds": [],
"companyNames": [],
"companySegments": [],
"descriptionFormat": "text",
"employmentGradeMax": 100,
"employmentGradeMin": 0,
"employmentTypes": [],
"includeDetails": false,
"incrementalMode": false,
"industries": [],
"languageSkills": [],
"locale": "en",
"location": "",
"maxDescriptionLength": 0,
"maxItems": 3,
"maxPages": 1,
"mode": "search",
"positions": [],
"publishedSince": "",
"regions": [],
"searchMode": "classic",
"searchQueries": [
"software engineer"
],
"sortBy": "relevance",
"startUrls": [],
"stateKey": ""
}
Download input.example.json and save your reviewed copy as input.json.
| Field | Type | Required | Description |
|---|---|---|---|
mode | string | required | What to fetch. `search` runs classic keyword search (or semantic with `searchMode=semantic`). `browse` uses filters only. `byCompany` resolves company names/IDs. `byUrls` accepts jobs.ch search or job-detail URLs. The `byRegion`/`byIndustry`/`byEmploymentType`/`byCategory` modes are kept for backward compatibility and require their matching filter. |
searchMode | string | optional | `classic` uses jobs.ch's exact keyword API with all filters and sort. `semantic` uses the site's fuzzy, cross-language search page (filters still apply; sort is relevance-only). |
searchQueries | array | optional | One or more free-text keywords (mode=search). Multiple queries are run in order and deduplicated by job ID. Leave empty to browse all jobs matching the filters. |
companyNames | array | optional | Company names to resolve against jobs.ch's company directory (mode=byCompany). Exact names are preferred; unmatched names fall back to a keyword search filtered by company name. |
companyIds | array | optional | jobs.ch company IDs (mode=byCompany). IDs are the most reliable company filter and take priority over names. |
startUrls | array | optional | jobs.ch search URLs or job-detail URLs (mode=byUrls). Search URLs carry their own filters; invalid or non-jobs.ch URLs are skipped. |
regions | array | optional | Filter by one or more Swiss canton/language-regions (multi-value OR). Allowed IDs: 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25. Required for mode=byRegion; optional elsewhere. |
industries | array | optional | Filter by one or more employer industries (multi-value OR). Allowed IDs: 1-24. Required for mode=byIndustry; optional elsewhere. |
categories | array | optional | Filter by one or more occupational fields / job functions (multi-value OR). Allowed IDs: 97-261 (165 jobs.ch categories; labels in README). Required for mode=byCategory. |
employmentTypes | array | optional | Filter by one or more contract types (multi-value OR). Allowed IDs: 1 Temporary, 2 Freelance, 3 Internship, 4 Supplementary income, 5 Permanent position, 6 Apprenticeship. Required for mode=byEmploymentType. |
positions | array | optional | Filter by one or more seniority levels (multi-value OR). Allowed IDs: 1 Executive position, 2 Specialist, 3 Employee. |
languageSkills | array | optional | Filter by one or more required working languages (multi-value OR). Allowed values: de, en, fr, it. |
companySegments | array | optional | Filter by employer segment (multi-value OR). Allowed values: gu (large company), kmu (SME), pdl (personnel-service provider). |
location | string | optional | Optional free-text city/place refinement (e.g. Zürich, Geneva, Basel). |
employmentGradeMin | integer | optional | Lower bound of the workload range in percent. |
employmentGradeMax | integer | optional | Upper bound of the workload range in percent. |
publishedSince | string | optional | Only jobs first published within this time window. |
sortBy | string | optional | Classic search sort order: relevance or newest-first. Semantic search always uses relevance. |
includeDetails | boolean | optional | Fetch each job's detail page for full description, apply URL/method, salary estimate, contacts, languages, categories, regions, deadline, benefits and company profile/ratings. Adds one request per job plus one cached request per company. |
descriptionFormat | string | optional | Format of the enriched description: plain text, original HTML, or both. |
maxDescriptionLength | integer | optional | Truncate descriptions to this many characters (0 = no truncation). |
maxItems | integer | optional | Maximum number of jobs to return. jobs.ch serves 20 rows per page and caps each search at 2,000 rows. |
maxPages | integer | optional | Maximum result pages to request per query/filter combination (jobs.ch caps searches at 100 pages). |
locale | string | optional | jobs.ch site language for URLs and translated labels. |
incrementalMode | boolean | optional | When enabled, only new or changed jobs are pushed. State is stored under `stateKey` in the key-value store. |
stateKey | string | optional | Key-value store key for incremental state (default `jobs_ch_incremental_state`). Only used when `incrementalMode` is true. |
3. Start an Actor run
Set APIFY_TOKEN in your environment. Python 3.10 or newer is sufficient; this recipe uses no third-party packages.
Execution may incur charges. Review current pricing on Apify. The request asks for a 120-second timeout and a charge limit; these settings are subject to Apify’s pricing and do not guarantee an all-inclusive spending cap.
import json
import os
import urllib.request
# Save the schema-derived example as input.json; review and edit it first.
with open("input.json", encoding="utf-8") as stream:
actor_input = json.load(stream)
token = os.environ["APIFY_TOKEN"]
request = urllib.request.Request(
"https://api.apify.com/v2/acts/s0z4uLgc6jZVLtD28/runs?timeout=120&maxTotalChargeUsd=0.50",
data=json.dumps(actor_input).encode("utf-8"),
headers={"Authorization": "Bearer " + token, "Content-Type": "application/json"},
method="POST",
)
# This starts a potentially billable run. Do not automatically retry this POST.
with urllib.request.urlopen(request, timeout=40) as response:
run = json.load(response)["data"]
print("Run ID:", run["id"])
print("Status:", run["status"])
# Inspect and download results in Apify Console once the run succeeds.
4. Inspect the actual results
Open the run in Apify Console and wait for a successful completion. Use the published output schema to locate results and the dataset schema to understand declared views. Missing or optional record fields must not be treated as guaranteed values.
jobs.ch job records with listings, descriptions, salary estimates, apply links, contacts, languages, categories, regions and company profiles.
Questions before you run
Which inputs are required?
The published required fields are mode
What does this guide verify?
The fields, prefills, and schema links are rendered from the published build. This is a usage recipe, not a paid live extraction test. Source availability and collection results can vary.
What if the run request times out?
Check Apify Console before retrying. The first request may already have created a run. Do not automatically repeat a run-creation POST.
Generated from source build 9evTfDGOOXMYXba9u and its README and schemas. Source changes regenerate this guide; no third-party editorial claims are inferred.