# Gear Calculator (AGMA Spur Gear Bending, Pitting, Sizing) (`jumblemog/gear-calculator`) Actor

Spur gear calculator from plain text: AGMA bending and contact stresses, safety factors, geometry factor J from the generated tooth, Kv, Ks, Km, life and reliability factors, tooth geometry, forces, rated power, and module sizing.

- **URL**: https://apify.com/jumblemog/gear-calculator.md
- **Developed by:** [Jumble Mog](https://apify.com/jumblemog) (community)
- **Categories:** AI, Automation, Developer tools
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Gear Calculator (AGMA Spur Gear Bending, Pitting, Sizing)

**Will the gears last? Describe the pair in one line and find out.** Type `17 and 52 teeth, 10 DP, 20°, face 1.5 in, 4 hp at 1800 rpm, Qv 6, 240 HB, 1e8 cycles, 90% reliability` or `find the module: ratio 3, 5 kW at 1450 rpm, pinion 300 HB, gear 250 HB, 20000 hours`. You get back:

- **The tooth geometry**: pitch, outside, root and base diameters, center distance, circular and base pitch, addendum, dedendum, contact ratio, and the fewest pinion teeth that mesh without interference.
- **The forces**: tangential, radial and normal tooth loads, both torques and the pitch-line velocity.
- **The bending geometry factor J computed from the tooth itself**, by the AGMA 908 method: the tooth is generated by a standard rack, loaded at the highest point of single-tooth contact, and checked at the Lewis parabola's critical section with the fillet stress concentration. No chart reading.
- **Every AGMA 2001 factor**, shown: overload Ko, dynamic Kv from the quality number, size Ks, load distribution Km (with Cpf, Cpm, Cma, Cmc), rim KB, life YN and ZN, reliability KR, hardness ratio CH, the elastic coefficient Cp and the pitting factor I.
- **Bending and contact stresses** for the pinion and the gear, against their allowables.
- **Four safety factors**: bending and pitting, pinion and gear, which one governs, and the power the pair can carry for the life you asked for.
- **For design requests**: the smallest standard module (or diametral pitch) that meets your safety target, or the face width when the module is fixed.
- **A chart**: the pinion tooth to scale with the load point, the load line, the Lewis parabola and the critical section, next to the four safety factors.

Materials: through-hardened steel by Brinell hardness (AGMA grade 1 or 2), carburized and hardened steel (grade 1 to 3), gray cast iron class 20, 30 or 40, or your own St and Sc. Pinion and gear can differ. Metric (module, mm, kW, N·m, MPa) or inch (diametral pitch, in, hp, lbf·in, kpsi): results come back in the units you wrote.

It's made for:

- Mechanical designers sizing gearbox, conveyor and machine-drive gears.
- Engineering students working Shigley-style AGMA problems.
- Maintenance engineers checking whether a replacement gear set will hold.
- AI agents that need real gear-strength numbers instead of a guess.

![A module 3, 20/60 carburized spur gear pair analyzed by this Actor: the pinion tooth drawn to scale with the load at the highest point of single-tooth contact, the Lewis parabola and the critical section, next to safety factors of 2.19 and 2.58 in bending and 1.29 and 1.36 in pitting](https://api.apify.com/v2/key-value-stores/Km5b4PG3kYHdZSb1E/records/gear-calculator-example.png?signature=cgv0EiIlmb1mYIpBohR9)

### How to use it

1. Write **Gear pairs**, one pair per entry. The form has examples.
2. Optionally set a **Default steel hardness**, **quality number**, **reliability**, **gearing** class or the **Units**.
3. Click **Start**. Each pair is a row in the results, with its summary, chart and report.

#### Writing a pair

| You write | It means |
|---|---|
| `17 and 52 teeth`, `18-tooth pinion, 45-tooth gear`, `pinion 20 teeth, ratio 3` | the tooth counts |
| `module 2.5`, `10 DP`, `diametral pitch 8` | the tooth size |
| `20°`, `25 deg pressure angle` | the pressure angle (20° if not given) |
| `face 30 mm`, `face width 1.5 in` | the face width (about 12 modules if not given) |
| `4 hp at 1800 rpm`, `3 kW, 1450 rpm`, `torque 20 N·m` | the load and the pinion speed |
| `240 HB`, `pinion 300 HB, gear 250 HB`, `grade 2`, `carburized`, `cast iron class 30`, `St 30 kpsi, Sc 110 kpsi` | the materials |
| `Qv 8` | the AGMA quality number (6 if not given) |
| `1e8 cycles`, `20000 hours` | the pinion life (10⁷ cycles if not given) |
| `99% reliability` | the reliability (99% if not given) |
| `overload 1.25`, `light shock motor, moderate shock load` | the overload factor |
| `overhung`, `open gearing`, `precision`, `extra precision`, `crowned` | mounting and alignment for Km |
| `Jp 0.30, Jg 0.40`, `Cp 2300` | your own geometry factors or elastic coefficient |
| `find the module ...`, `safety 1.5` | size it, and the target |

Objects work too; see Input.

### Examples

All of these ran on this Actor; the numbers are from the results.

| Pair | Result |
|---|---|
| `17 and 52 teeth, 10 DP, 20°, face 1.5 in, 4 hp at 1800 rpm, Qv 6, 240 HB, 1e8 cycles, 90% reliability` (Shigley Example 14-4) | Wt 164.8 lbf, Kv 1.377, Ks 1.043/1.052, Km 1.22 as in the book; J 0.328/0.400 (book chart 0.30/0.40); bending safety 6.13/7.58, pitting 1.70/1.73 (book 1.69/1.73); rated 11.5 hp |
| `module 3, 20 and 60 teeth, face 36 mm, 15 kW at 1000 rpm, carburized, Qv 8, precision, crowned` | 4775 N tangential load; bending 176/151 MPa, contact 963 MPa; safety 2.19/2.58 bending, 1.29/1.36 pitting; rated 24.9 kW |
| `find the module: ratio 3, 5 kW at 1450 rpm, pinion 300 HB, gear 250 HB, 20000 hours, safety 1.2` | Module 3, 18/54 teeth, face 36 mm; gear pitting governs at 1.21 over 1.74·10⁹ pinion cycles |
| Conveyor drive: 24/72 teeth, module 4, 25°, face 48 mm, 2 kW at 300 rpm, 280 HB steel pinion, cast iron class 30 gear, overhung, open gearing, moderate shock | Cast iron gear limits it: bending 2.06, pitting 1.31; rated 3.4 kW |
| `18-tooth pinion driving a 45-tooth gear, 8 diametral pitch, 2 in face, torque 900 lbf·in, 1200 rpm, 300 HB grade 2, heavy shock load` | Ko 1.75; pitting safety 0.87 under 1, with a warning; rated 13 hp |

The tests check that:

- Shigley's Example 14-4 comes out: Kv, Ks, Km, KR, YN, ZN, and, with the book's J, its bending and contact stresses and safety factors.
- The computed J matches AGMA values (0.40 for the 52-tooth gear of Example 14-4, 0.41 for a 55-tooth gear with 26 teeth).
- A pair written in metric and the same pair in inches give the same safety factors.
- Tooth counts, separate pinion and gear materials, hours, shock classes and ratios are read correctly.
- The design module is the smallest standard one that works.

### How-to examples

Each example is a complete input; the results are from runs of the Actor (also listed under **Examples**).

#### How to check a spur gear pair for bending and pitting (AGMA 2001)

```json
{"gears": ["17 and 52 teeth, 10 DP, 20°, face 1.5 in, 4 hp at 1800 rpm, Qv 6, 240 HB, 1e8 cycles, 90% reliability"]}
```

Result: this is Shigley's Example 14-4: Wt 164.8 lbf, Kv 1.377, Km 1.22 as in the book; bending safety 6.13/7.58, pitting 1.70/1.73 (book 1.69/1.73); rated 11.5 hp.

#### How to choose the gear module for a power and life

```json
{"gears": ["find the module: ratio 3, 5 kW at 1450 rpm, pinion 300 HB, gear 250 HB, 20000 hours, safety 1.2"]}
```

Result: module 3, 18/54 teeth and a 36 mm face; gear pitting governs at 1.21 over 1.74·10⁹ pinion cycles.

#### How to rate metric gears with carburized teeth

```json
{"gears": ["module 3, 20 and 60 teeth, face 36 mm, 15 kW at 1000 rpm, carburized, Qv 8, precision, crowned"]}
```

Result: 4775 N tangential load; bending 176/151 MPa and contact 963 MPa; safety 2.19/2.58 in bending and 1.29/1.36 in pitting; rated 24.9 kW.

#### How to let an AI agent size gears

Add this Actor to the [Apify MCP server](https://mcp.apify.com) with `https://mcp.apify.com/?tools=jumblemog/gear-calculator`. The agent describes the pair in one line and answers with the safety factors, which failure governs and the power rating.

### FAQ

**Which gears does it cover?** External spur gears with standard full-depth teeth. Helical, bevel, worm and internal gears aren't covered.

**Where does the J factor come from?** It is computed from the generated tooth by the AGMA 908 method, within a few percent of AGMA's tables. Give `Jp` and `Jg` to use your own.

**Can the pinion and gear be different materials?** Yes: through-hardened steel by Brinell hardness, carburized steel, gray cast iron class 20, 30 or 40, or your own St and Sc, set for each one.

**What isn't checked?** Scoring and scuffing, micropitting, lubrication and temperatures above 250 °F. Check shafts, bearings and keys separately.

### Input

| Field | What it is |
|---|---|
| `gears` | Gear pairs, as text or objects. |
| `hardness` | Default steel hardness in HB, for pairs that don't name a material. |
| `quality` | Default AGMA quality number Qv (6). |
| `reliability` | Default reliability in % (99). |
| `enclosure` | Default gearing: `open`, `commercial` (default), `precision` or `extra precision`. |
| `units` | `mm` (default) or `in`, for numbers written without a unit. |
| `charts` | Draw charts (default on). |

**A pair as an object** takes:

- `pinionTeeth`, `gearTeeth` (or `ratio`), `module` or `diametralPitch`, `pressureAngle`, `faceWidth`.
- `power` or `torque` (on the pinion), `rpm` (pinion).
- `material`, `hardness`, `grade`, or per member `pinionMaterial`, `gearMaterial`, `pinionHardness`, `gearHardness`; `st`, `sc` to override the allowables.
- `quality`, `overload` or `shock`, `reliability`, `cycles` or `hours`, `mounting` (`straddle` or `overhung`), `enclosure`, `crowned`, `rimFactor`.
- `jPinion`, `jGear`, `cp`, `tipRadius` (the generating rack's tip radius in modules, 0.25 by default).
- `mode` (`analyze` or `design`), `safety` (design target, default 1.5), `units`, `title`, and `text` (a line of text, with the other fields overriding what it says).

### Output

One dataset item per pair, also saved together in the run's `OUTPUT` record:

```json
{
  "request": 2, "status": "ok", "type": "gear", "mode": "analyze", "title": "20/60 spur gears, module 3",
  "units": {"length": "mm", "force": "N", "stress": "MPa", "power": "kW", "torque": "N·m", "velocity": "m/s"},
  "mesh": {"module": 3.0, "pressureAngle": 20.0, "faceWidth": 36.0, "ratio": 3.0, "centerDistance": 120.0,
           "contactRatio": 1.671, "pitchLineVelocity": 3.142, "quality": 8.0},
  "pinion": {"teeth": 20, "pitchDiameter": 60.0, "outsideDiameter": 66.0, "rootDiameter": 52.5,
             "material": "Carburized and hardened steel, grade 1", "st": 379.21, "sc": 1241.06, "j": 0.3514,
             "jDetails": {"y": 0.6819, "kf": 1.9408, "hF": 0.9617, "sF": 1.893, "rhoF": 0.3412}},
  "loads": {"power": 15.0, "tangentialForce": 4774.6, "radialForce": 1737.8, "pinionTorque": 143.239},
  "safety": {"bendingPinion": 2.193, "bendingGear": 2.582, "pittingPinion": 1.288, "pittingGear": 1.365},
  "governs": "pittingPinion",
  "ratedPower": {"bending": 32.898, "pitting": 24.9018, "pair": 24.9018},
  "imageUrl": "https://api.apify.com/v2/key-value-stores/.../records/002-....png"
}
```

Each item also has `gear`, `factors` (every AGMA factor), `bending` and `contact` (stress, allowable and safety for each member). A design adds `design` with the target and the size found. Every item has `warnings`, `notes` (the formulas and assumptions), a Markdown `report` and links to the chart and report. A request that can't be computed has `"status": "failed"` and the reason in `error`, and isn't billed.

### How it works

1. **Reading**: each line is read for the teeth, size, load, speed, materials and options; numbers carry their units.
2. **Geometry**: standard full-depth teeth (addendum 1, dedendum 1.25 modules); contact ratio from the line of action; interference limit from Shigley eq. 13-11.
3. **J factor (AGMA 908)**: the fillet is traced by the tip round of the generating rack; the load sits at the highest point of single-tooth contact; the critical section is where the Lewis parabola from the load line's crossing of the tooth centerline touches the fillet; Y includes the radial compression, and the stress correction Kf = H + (s/ρ)^L (s/h)^M uses the minimum fillet radius.
4. **Stresses (AGMA 2001)**: σ = Wt·Ko·Kv·Ks·(Pd/F)·(Km·KB/J) and σc = Cp·√(Wt·Ko·Kv·Ks·Km·Cf/(d·F·I)), with Kv from Qv, Ks from the Lewis form factor, and Km = 1 + Cmc(Cpf·Cpm + Cma·Ce) (Shigley eqs. 14-15 to 14-40).
5. **Strengths**: St and Sc from the hardness or the material table, with YN and ZN from the cycles, KR from the reliability, and CH for a harder pinion. SF = St·YN/(KT·KR)/σ and SH = Sc·ZN·CH/(KT·KR)/σc.
6. **Design**: standard modules (or pitches) from fine to coarse, each with a face of about 12 modules, until all four safety factors reach the target; with the module given, face widths from 3 to 5 circular pitches.

Results are engineering estimates for the stated assumptions; check shafts, bearings, keys, lubrication and scoring before building.

### Pricing

You pay one low price per gear pair, at the price shown on this page. It includes the chart and the report. Requests that can't be computed are never charged. If you set a maximum cost per run, the Actor stops before a request that wouldn't fit.

### Speed

A pair takes a few milliseconds and a module search a little more, plus the chart. A run through the API answers in about 5 to 10 seconds, including the cloud container starting.

### Tips and limits

- **Spur gears only**: external, standard (no profile shift), full-depth teeth. Helical, bevel, worm and internal gears aren't covered.
- **Computed J vs. charts**: the computed J lands within a few percent of AGMA's tables, usually a little above for small pinions. Give `Jp` and `Jg` to use your own.
- **Bending vs. pitting**: compare the bending safety with the pitting safety squared; the item's `governs` does that for you.
- **Not covered**: scoring and scuffing, micropitting, lubrication, temperatures above 250 °F (KT = 1).
- **Limits**: 500 pairs per run.

### For AI agents and developers

This Actor works with the [Apify MCP server](https://mcp.apify.com), so AI agents can call it as a tool. Pass `gears` as plain text and read `summary`, `safety`, `governs`, `ratedPower`, `warnings` and, for designs, `design.module`. A direct API call that waits for the answer:

```bash
curl -X POST "https://api.apify.com/v2/acts/jumblemog~gear-calculator/run-sync-get-dataset-items?token=YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"gears": ["find the module: 22-tooth pinion, ratio 4, 7.5 kW at 1450 rpm, carburized, Qv 8, 20000 hours, safety 1.5"]}'
```

`run-sync` instead returns the run's `OUTPUT`: the status, the counts and every result as JSON.

In Python, with the `apify-client` package:

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_TOKEN")
run = client.actor("jumblemog/gear-calculator").call(run_input={
    "gears": [{"pinionTeeth": 17, "gearTeeth": 52, "diametralPitch": 10, "faceWidth": "1.5 in",
               "power": "4 hp", "rpm": 1800, "hardness": 240, "cycles": 1e8, "reliability": 90}],
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["summary"])
```

### Credits

- Charts: [Vega-Lite](https://vega.github.io/vega-lite/) and [vl-convert](https://github.com/vega/vl-convert) (BSD-3-Clause), with the [Inter](https://rsms.me/inter/) font (SIL Open Font License).
- Method: AGMA 2001-D04 and AGMA 908-B89 as presented in Budynas and Nisbett, *Shigley's Mechanical Engineering Design*, chapters 13 and 14.

# Actor input Schema

## `gears` (type: `array`):

One gear pair per entry, as a line of text or an object. Give the teeth ('17 and 52 teeth', '18-tooth pinion, 45-tooth gear', or the pinion teeth and 'ratio 3'), the size ('module 2.5' or '10 DP'), the face width ('face 30 mm'), the load ('4 hp' or '3 kW', or 'torque 20 N·m') and the pinion speed ('1800 rpm'), and the material ('240 HB', 'pinion 300 HB, gear 250 HB', 'grade 2', 'carburized', 'cast iron class 30', or 'St 30 kpsi, Sc 110 kpsi'). Optional: '25°' pressure angle, 'Qv 8', '1e8 cycles' or '20000 hours', '99% reliability', 'overload 1.25' or 'moderate shock load', 'overhung', 'open gearing' / 'precision', 'crowned', 'Jp 0.30, Jg 0.40', 'Cp 2300'. Write 'find the module' (or leave the size out) to size it; with the size given and no face width, 'find' sizes the face. Object fields: mode, pinionTeeth, gearTeeth, ratio, module, diametralPitch, pressureAngle, faceWidth, power, rpm, torque, quality, overload, shock, reliability, cycles, hours, material, hardness, grade, pinionMaterial, gearMaterial, pinionHardness, gearHardness, st, sc, mounting, enclosure, crowned, rimFactor, jPinion, jGear, cp, tipRadius, safety, units, title.

## `hardness` (type: `string`):

For pairs that don't give a material, such as '250'. Through-hardened steel, AGMA grade 1.

## `quality` (type: `string`):

Sets the dynamic factor Kv. 6 (commercial) if unset.

## `reliability` (type: `string`):

Sets the reliability factor KR. 99% (the AGMA base) if unset.

## `enclosure` (type: `string`):

Sets the mesh alignment factor Cma in Km.

## `units` (type: `string`):

For numbers written without a unit. Inches, hp, lbf or DP in the text switch to inch units on their own.

## `charts` (type: `boolean`):

The pinion tooth to scale with the load and critical section, and the safety factors, for each pair.

## Actor input object example

```json
{
  "gears": [
    "17 and 52 teeth, 10 DP, 20°, face 1.5 in, 4 hp at 1800 rpm, Qv 6, 240 HB, 1e8 cycles, 90% reliability",
    "module 3, 20 and 60 teeth, face 36 mm, 15 kW at 1000 rpm, carburized, Qv 8, precision, crowned",
    "find the module: ratio 3, 5 kW at 1450 rpm, pinion 300 HB, gear 250 HB, 20000 hours, safety 1.2",
    {
      "title": "Conveyor drive, cast iron gear",
      "pinionTeeth": 24,
      "gearTeeth": 72,
      "module": 4,
      "pressureAngle": 25,
      "faceWidth": "48 mm",
      "power": "2 kW",
      "rpm": 300,
      "pinionHardness": 280,
      "gearMaterial": "cast iron class 30",
      "mounting": "overhung",
      "enclosure": "open",
      "shock": "moderate"
    }
  ],
  "units": "mm",
  "charts": true
}
```

# Actor output Schema

## `results` (type: `string`):

One row per gear pair: the summary and chart.

## `output` (type: `string`):

The OUTPUT record: every result in one JSON object.

## `files` (type: `string`):

Charts (PNG and SVG) and Markdown reports in the run's key-value store.

# 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 = {
    "gears": [
        "17 and 52 teeth, 10 DP, 20°, face 1.5 in, 4 hp at 1800 rpm, Qv 6, 240 HB, 1e8 cycles, 90% reliability",
        "module 3, 20 and 60 teeth, face 36 mm, 15 kW at 1000 rpm, carburized, Qv 8, precision, crowned",
        "find the module: ratio 3, 5 kW at 1450 rpm, pinion 300 HB, gear 250 HB, 20000 hours, safety 1.2",
        {
            "title": "Conveyor drive, cast iron gear",
            "pinionTeeth": 24,
            "gearTeeth": 72,
            "module": 4,
            "pressureAngle": 25,
            "faceWidth": "48 mm",
            "power": "2 kW",
            "rpm": 300,
            "pinionHardness": 280,
            "gearMaterial": "cast iron class 30",
            "mounting": "overhung",
            "enclosure": "open",
            "shock": "moderate"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("jumblemog/gear-calculator").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 = { "gears": [
        "17 and 52 teeth, 10 DP, 20°, face 1.5 in, 4 hp at 1800 rpm, Qv 6, 240 HB, 1e8 cycles, 90% reliability",
        "module 3, 20 and 60 teeth, face 36 mm, 15 kW at 1000 rpm, carburized, Qv 8, precision, crowned",
        "find the module: ratio 3, 5 kW at 1450 rpm, pinion 300 HB, gear 250 HB, 20000 hours, safety 1.2",
        {
            "title": "Conveyor drive, cast iron gear",
            "pinionTeeth": 24,
            "gearTeeth": 72,
            "module": 4,
            "pressureAngle": 25,
            "faceWidth": "48 mm",
            "power": "2 kW",
            "rpm": 300,
            "pinionHardness": 280,
            "gearMaterial": "cast iron class 30",
            "mounting": "overhung",
            "enclosure": "open",
            "shock": "moderate",
        },
    ] }

# Run the Actor and wait for it to finish
run = client.actor("jumblemog/gear-calculator").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 '{
  "gears": [
    "17 and 52 teeth, 10 DP, 20°, face 1.5 in, 4 hp at 1800 rpm, Qv 6, 240 HB, 1e8 cycles, 90% reliability",
    "module 3, 20 and 60 teeth, face 36 mm, 15 kW at 1000 rpm, carburized, Qv 8, precision, crowned",
    "find the module: ratio 3, 5 kW at 1450 rpm, pinion 300 HB, gear 250 HB, 20000 hours, safety 1.2",
    {
      "title": "Conveyor drive, cast iron gear",
      "pinionTeeth": 24,
      "gearTeeth": 72,
      "module": 4,
      "pressureAngle": 25,
      "faceWidth": "48 mm",
      "power": "2 kW",
      "rpm": 300,
      "pinionHardness": 280,
      "gearMaterial": "cast iron class 30",
      "mounting": "overhung",
      "enclosure": "open",
      "shock": "moderate"
    }
  ]
}' |
apify call jumblemog/gear-calculator --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,jumblemog/gear-calculator"
        }
    }
}
```

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/B7Bnxvf9ph1ynmjhW/builds/973tmWn9dg1CYhN23/openapi.json
