# Bayt Jobs Scraper — MENA Listings with Full JobPosting Data (`axery/bayt-jobs-scraper`) Actor

Scrape Bayt.com job listings across the Middle East and North Africa with full JobPosting detail - description, employment type, dates, hiring organization and location - via a two-step search-then-detail crawl.

- **URL**: https://apify.com/axery/bayt-jobs-scraper.md
- **Developed by:** [Axery](https://apify.com/axery) (community)
- **Categories:** Jobs, Automation, News
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.80 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Bayt Jobs Scraper (MENA)

Scrapes job listings from **bayt.com** — the largest job board across the Middle East and North Africa — over plain HTTP. No browser, no login.

### Two-step scrape, because Bayt's search page alone isn't enough

Bayt's search results carry a JSON-LD `ItemList`, but it's just 30 URLs — no salary, no company, no description. The full record lives on each job's own page, as a proper schema.org `JobPosting` block. This Actor fetches both: the search page for the URL list, then each job page for the complete record.

That means one listing costs two HTTP fetches, not one — reflected honestly in the per-job charge, since a two-step scrape has real cost the pricing should not hide.

### No free-text search — Bayt routes by URL path

There's no `?q=` parameter here. Bayt organizes search through URL paths like `en/uae/jobs/python-jobs`. To use this Actor, browse bayt.com, run the search you want, and copy the path segment after `bayt.com/`:

```json
{ "categoryPaths": ["en/uae/jobs/python-jobs", "en/saudi-arabia/jobs/accounting-jobs"] }
```

### What you get per job

```json
{
  "title": "Senior Backend Engineer – Node.js",
  "company": { "name": "Black Pearl", "profile_url": "https://www.bayt.com/en/company/black-pearl-1941858/" },
  "location": { "raw": "United Arab Emirates", "region": "United Arab Emirates", "country_code": "AE" },
  "employment_type": "FULL_TIME",
  "posted_at": "2026-08-12T17:00:00Z",
  "valid_through": "2026-10-12T00:00:00Z",
  "description_html": "..."
}
```

`location.country_code` is a proper ISO 3166-1 alpha-2 code — Bayt's own `addressCountry` field arrives as a bare code like `"AE"` rather than a full country name, and this Actor detects that shape rather than assuming one or the other.

### Salary is (almost) never there

`salary` is populated when Bayt's schema.org data discloses it, but in practice **`baseSalary` is null on effectively every listing** in this market — MENA job ads rarely publish pay. Don't build a pay-benchmark pipeline expecting otherwise; use this Actor for listing volume, company activity and description mining instead.

### Input

| Field | Type | Notes |
|---|---|---|
| `categoryPaths` | array | Bayt URL path segments, e.g. `en/uae/jobs/python-jobs`. |
| `maxItems` | integer | Per path. `0` = unlimited, bounded by Bayt's pagination depth. |
| `incremental` | boolean | Only listings not seen in previous runs. |
| `proxyConfiguration` | object | Datacenter is normally enough — no anti-bot layer encountered. |

### Known limits

- **Two fetches per row.** Slower and costs more per item than a single-page scrape, in exchange for a complete record instead of a title and a link.
- **No numeric salary in practice.** See above.
- **No free-text search.** You navigate by category path, not by keyword.

### Local development

```bash
pip install -r requirements.txt
python test_local.py "en/uae/jobs/python-jobs" --max 20 --out sample_output.json
python test_local.py "en/saudi-arabia/jobs/accounting-jobs" --max 10
```

`sample_output.json` in this folder is real output from a live run, kept so the schema can be reviewed without running anything.

# Actor input Schema

## `categoryPaths` (type: `array`):

Bayt routes searches through URL paths rather than a free-text query parameter. Browse bayt.com, run the search or category you want, and copy the path after bayt.com/ - for example 'en/uae/jobs/python-jobs' or 'en/saudi-arabia/jobs/accounting-jobs'. Each path runs independently and streams into the same dataset.

## `maxItems` (type: `integer`):

Maximum listings to return per category path. Set to 0 for unlimited, bounded by Bayt's own pagination depth.

## `incremental` (type: `boolean`):

Remember job ids between runs and return only listings not seen before. You are charged only for the new rows. Ids are stored in this Actor's key-value store under seen\_job\_ids.

## `proxyConfiguration` (type: `object`):

Apify Proxy settings. Defaults to Residential - the original build needed TLS-fingerprint rotation to get past Bayt's WAF from a bare connection, indicating real IP/fingerprint sensitivity.

## Actor input object example

```json
{
  "categoryPaths": [
    "en/uae/jobs/python-jobs"
  ],
  "maxItems": 100,
  "incremental": false,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

## `jobs` (type: `string`):

One row per listing: title, company, location, employment type, posting and expiry dates, full description, and apply URL.

## `coverage` (type: `string`):

What the run asked for versus what it returned, and any category paths that failed.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "categoryPaths": [
        "en/uae/jobs/python-jobs"
    ],
    "maxItems": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("axery/bayt-jobs-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "categoryPaths": ["en/uae/jobs/python-jobs"],
    "maxItems": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("axery/bayt-jobs-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "categoryPaths": [
    "en/uae/jobs/python-jobs"
  ],
  "maxItems": 100
}' |
apify call axery/bayt-jobs-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,axery/bayt-jobs-scraper"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/ZT1w4wVSQ6bUlltcy/builds/u0byAkcAH40kZrQUz/openapi.json
