# Methods

> Find methods, read their contracts, publish or delete your own.

Source: https://docs.fous.com/api-reference/methods
Index: https://docs.fous.com/llms.txt

- `GET /v1/search`: Find methods
- `GET /v1/methods`: List your methods
- `GET /v1/methods/{domain}/{name}`: Get a method
- `PATCH /v1/methods/{domain}/{name}`: Update a method
- `DELETE /v1/methods/{domain}/{name}`: Delete a method

## The Method object

- `id` (string, required): mth_ followed by 26 characters.
- `slug` (string, required): <domain>/<snake_case_name>, one method’s own; accepted wherever an id is.
- `name` (string, required)
- `description` (string, required)
- `returns` (string, required): What the output holds, in a few words.
- `platform` (object, required)
  - `name` (string)
  - `domain` (string)
- `input_schema` (object, required): A flat JSON Schema object: snake_case properties with descriptions; required lists the inputs a call must send.
- `auth` (object, required)
  - `required` (boolean, required): Whether the method runs with a connected account.
  - `type` (string): session: a website login; api_key: the site’s own API key. One of `session`, `api_key`.
  - `connection` (string or null): Your default connection for this platform, if any.
- `effect` (string, required): read: it gets data. write: it does something on the site (submits, posts, books, sends); run it with care. One of `read`, `write`.
- `cost` (object, required)
  - `credits` (integer)
- `private` (boolean): Present (true) on your organization’s methods that are not published.
- `version` (integer, required): The version shown: the one your organization uses (its pin, else the latest), or the one the ref named (@N). A version is a contract: its inputs and outputs never change.
- `latest_version` (integer, required): The method’s newest version.
- `status` (string): In a search result, present only when the version is not ready: degraded (failing: its saved examples stopped answering, and no run has answered since; runs are still attempted, and Fous repairs it) or repairing (a repair confirmed the break while runs failed too; runs are refused with 503 method_repairing until it ends, at the latest at repair.expected_at). One of `degraded`, `repairing`.
- `repair` (object): Only while repairing: when the version is back at the latest. A repair that has not confirmed a break is never shown.
  - `expected_at` (string, required)
  - `back_in_minutes` (integer, required)
- `last_repair` (object): While degraded, when a repair ran and could not fix the version: when it ended and why, in its own words. Fous checks the version every hour and repairs it again later.
  - `at` (string, required)
  - `reason` (string, required)
- `deletes_at` (string): A public method nobody has run for 6 months: when it is deleted unless it runs (any run keeps it).

```json
{
  "id": "mth_01m5kvvywdeac8fxs7nh0sw68w",
  "slug": "date.nager.at/list_public_holidays",
  "name": "List public holidays",
  "description": "Lists a country's public holidays for a year from Nager.Date, with local names, regional coverage and holiday types.",
  "returns": "date, weekday, English and local names, regions, type, nationwide flag",
  "platform": {
    "name": "Nager.Date",
    "domain": "nager.at"
  },
  "input_schema": {
    "type": "object",
    "required": [
      "country"
    ],
    "properties": {
      "year": {
        "type": "integer",
        "minimum": 1,
        "maximum": 9999,
        "description": "Calendar year, for example 2026. Defaults to the current year."
      },
      "country": {
        "type": "string",
        "description": "Country name or two-letter country code, for example Germany or DE."
      }
    }
  },
  "effect": "read",
  "auth": {
    "required": false
  },
  "cost": {
    "credits": 1
  },
  "version": 2,
  "latest_version": 2
}
```

## The MethodListItem object

Every field of [Method](#the-method-object), and the fields below, which are new or read differently.

- `status` (string, required): How the version shown stands: ready (any answer with data makes it ready at once); degraded (failing: its saved examples stopped answering, and no run has answered since; runs are still attempted, and Fous repairs it); repairing (a repair confirmed the break while runs failed too; runs are refused with 503 method_repairing until it ends, at the latest at repair.expected_at). One of `ready`, `degraded`, `repairing`.
- `pinned_version` (integer or null, required): The version your organization uses: set by its first run (owners too), moved by PATCH {"pinned_version": N} or by a new version it builds itself. Null until a run.
- `visibility` (string, required): private: only your organization finds and runs it. public: anyone may; it stays public, and anyone may improve it. One of `public`, `private`.
- `stats` (object, required): How the method has done so far.
  - `success_rate` (number or null)
  - `runs` (integer)
  - `last_success_at` (string or null)
- `owned` (boolean, required): Your organization built it: it publishes it, and deletes it while it is private.
- `based_on` (object): The method (and its version) this one was started from.
  - `id` (string, required)
  - `slug` (string, required)
  - `name` (string, required)
  - `version` (integer): The version, when one is meant.
- `created_at` (string, required)
- `updated_at` (string, required)

```json
{
  "id": "mth_01m5kz9a1b2c3d4e5f6g7h8j9k",
  "slug": "crates.io/search_crates",
  "name": "Search crates",
  "description": "Searches crates.io by keyword.",
  "returns": "name, description, downloads, version",
  "platform": {
    "name": "crates.io",
    "domain": "crates.io"
  },
  "input_schema": {
    "type": "object",
    "required": [
      "query"
    ],
    "properties": {
      "query": {
        "type": "string",
        "description": "Keyword."
      }
    }
  },
  "effect": "read",
  "auth": {
    "required": false
  },
  "cost": {
    "credits": 1
  },
  "version": 1,
  "latest_version": 1,
  "private": true,
  "status": "ready",
  "pinned_version": 1,
  "visibility": "private",
  "owned": true,
  "stats": {
    "success_rate": 1,
    "runs": 4,
    "last_success_at": "2026-10-23T09:02:11.000Z"
  },
  "created_at": "2026-10-23T08:41:12.000Z",
  "updated_at": "2026-10-23T08:41:12.000Z"
}
```

## The MethodDetail object

Every field of [Method](#the-method-object), and the fields below, which are new or read differently.

- `status` (string, required): How the version shown stands: ready (any answer with data makes it ready at once); degraded (failing: its saved examples stopped answering, and no run has answered since; runs are still attempted, and Fous repairs it); repairing (a repair confirmed the break while runs failed too; runs are refused with 503 method_repairing until it ends, at the latest at repair.expected_at). One of `ready`, `degraded`, `repairing`.
- `pinned_version` (integer or null, required): The version your organization uses: set by its first run (owners too), moved by PATCH {"pinned_version": N} or by a new version it builds itself. Null until a run.
- `visibility` (string, required): private: only your organization finds and runs it. public: anyone may; it stays public, and anyone may improve it. One of `public`, `private`.
- `stats` (object, required): How the method has done so far.
  - `success_rate` (number or null)
  - `runs` (integer)
  - `last_success_at` (string or null)
- `owned` (boolean, required): Your organization built it: it publishes it, and deletes it while it is private.
- `based_on` (object): The method (and its version) this one was started from.
  - `id` (string, required)
  - `slug` (string, required)
  - `name` (string, required)
  - `version` (integer): The version, when one is meant.
- `revision` (integer, required): How many times the version shown was revised in place (a repair or an improvement that kept its contract); the seen parameter carries it.
- `latest_changes` (string): When the version shown is not the latest: what the latest changes against it, in a sentence or two.
- `versions` (array of object, required): The method’s versions, newest first (at most 20).
  - `version` (integer, required)
  - `revision` (integer, required)
  - `latest` (boolean): The newest version. Must be `true`.
  - `pinned` (boolean): The version your organization uses. Must be `true`.
  - `status` (string, required): One of `ready`, `degraded`, `repairing`.
  - `created_at` (string, required)
  - `revised_at` (string): When it was last revised in place.
  - `changes` (string, required): What it changes against the version before it; empty for the first.
- `output_schema` (object, required): The JSON Schema every run’s data follows.
- `example` (object)
  - `input` (object)
  - `output` (JSON value)

```json
{
  "id": "mth_01m5kvvywdeac8fxs7nh0sw68w",
  "slug": "date.nager.at/list_public_holidays",
  "name": "List public holidays",
  "description": "Lists a country's public holidays for a year from Nager.Date, with local names, regional coverage and holiday types.",
  "returns": "date, weekday, English and local names, regions, type, nationwide flag",
  "platform": {
    "name": "Nager.Date",
    "domain": "nager.at"
  },
  "input_schema": {
    "type": "object",
    "required": [
      "country"
    ],
    "properties": {
      "year": {
        "type": "integer",
        "minimum": 1,
        "maximum": 9999,
        "description": "Calendar year, for example 2026. Defaults to the current year."
      },
      "country": {
        "type": "string",
        "description": "Country name or two-letter country code, for example Germany or DE."
      }
    }
  },
  "effect": "read",
  "auth": {
    "required": false
  },
  "cost": {
    "credits": 1
  },
  "version": 2,
  "latest_version": 2,
  "revision": 1,
  "pinned_version": null,
  "status": "ready",
  "versions": [
    {
      "version": 2,
      "revision": 1,
      "latest": true,
      "status": "ready",
      "created_at": "2026-10-22T16:02:41.000Z",
      "changes": "Adds output holidays[].regions."
    },
    {
      "version": 1,
      "revision": 2,
      "status": "ready",
      "created_at": "2026-10-21T09:12:05.000Z",
      "revised_at": "2026-10-24T03:10:19.000Z",
      "changes": ""
    }
  ],
  "visibility": "public",
  "output_schema": {
    "type": "object",
    "properties": {
      "country_name": {
        "type": "string"
      },
      "year": {
        "type": "integer"
      },
      "holidays": {
        "type": "array",
        "items": {
          "type": "object"
        }
      }
    }
  },
  "example": {
    "input": {
      "country": "Germany",
      "year": 2027
    },
    "output": {
      "country_name": "Germany",
      "year": 2027,
      "holidays": [
        {
          "date": "2027-01-01",
          "weekday": "Friday",
          "english_name": "New Year's Day",
          "local_name": "Neujahr",
          "nationwide": "yes",
          "regions": [],
          "type": "Public"
        }
      ]
    }
  },
  "stats": {
    "success_rate": 1,
    "runs": 12,
    "last_success_at": "2026-10-23T08:24:36.410Z"
  },
  "owned": false
}
```

## Find methods

`GET https://api.fous.com/v1/search`

Describe what you need in plain language. Returns the methods that fit, best first, each with its effect (read or write) and input schema, or match "none". Search never builds: when nothing fits, build one with POST /v1/builds. Free.

### Query parameters

- `query` (string): What you need, in plain language.
- `platform` (string): A domain or site name to search within; alone, it lists that site’s methods.
- `limit` (integer): How many: 1 to 20 with a query (default 5); a site listed without a query, up to 100 (default 100).
- `suggest` (boolean): Search as someone types: the methods nearest the text so far (its last word may be unfinished), without checking which do it all, so results, suggested: true, and no match or reason. Five a minute for each of the plan’s requests, counted apart from searches. Default false.

### Returns

- `200`: Methods that fit, or none. With suggest=true, the nearest methods.

The answer has these fields:

- `results` ([array of Method](https://docs.fous.com/api-reference/methods.md#the-method-object), required)
- `match` (string): Always sent, except with suggest=true. One of `found`, `none`.
- `suggested` (boolean): With suggest=true: the results are unchecked suggestions. Must be `true`.
- `related` ([array of Method](https://docs.fous.com/api-reference/methods.md#the-method-object)): On a miss: methods that do part of what was asked (unchecked when Fous could not check fit just then; reason says so).
- `reason` (string): On a miss: why nothing fits (a request that names only a topic), that POST /v1/builds can make it, or that Fous could not check fit just then.

### Errors

| Status | Code | When |
| --- | --- | --- |
| 400 | `invalid_request` | Neither query nor platform |
| 401 | `unauthorized` | No valid key |
| 429 | `rate_limited` | Too many searches for the plan this minute |

### Example request

```bash
curl 'https://api.fous.com/v1/search?query=public+holidays+in+Germany+next+year' \
  -H "Authorization: Bearer $FOUS_API_KEY"
```

With every optional parameter:

```bash
curl 'https://api.fous.com/v1/search?query=public+holidays+in+Germany+next+year&platform=crates.io&limit=50&suggest=true' \
  -H "Authorization: Bearer $FOUS_API_KEY"
```

### Response 200

```json
{
  "results": [
    {
      "id": "mth_01m5kvvywdeac8fxs7nh0sw68w",
      "slug": "date.nager.at/list_public_holidays",
      "name": "List public holidays",
      "description": "Lists a country's public holidays for a year from Nager.Date, with local names, regional coverage and holiday types.",
      "returns": "date, weekday, English and local names, regions, type, nationwide flag",
      "platform": {
        "name": "Nager.Date",
        "domain": "nager.at"
      },
      "input_schema": {
        "type": "object",
        "required": [
          "country"
        ],
        "properties": {
          "year": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9999,
            "description": "Calendar year, for example 2026. Defaults to the current year."
          },
          "country": {
            "type": "string",
            "description": "Country name or two-letter country code, for example Germany or DE."
          }
        }
      },
      "effect": "read",
      "auth": {
        "required": false
      },
      "cost": {
        "credits": 1
      },
      "version": 2,
      "latest_version": 2
    }
  ],
  "match": "found"
}
```

### Error 400

```json
{
  "error": {
    "code": "invalid_request",
    "message": "Send query, platform, or both.",
    "doc_url": "https://docs.fous.com/guides/errors#invalid_request",
    "request_id": "req_mh7c2k9xQ1v3Zt8LbN0pRwY4"
  }
}
```

## List your methods

`GET https://api.fous.com/v1/methods`

Your organization’s own methods, private and published, the latest change first; or, with ids, any methods it sees, each at the version it uses, for a live re-read of their status. Free.

### Query parameters

- `platform` (string): Only the methods on this site (a domain or site name).
- `ids` (string): Method ids, comma-separated, at most 50: those methods instead of your own (owned says whose).

### Returns

- `200`: Your methods.

The answer has these fields:

- `methods` ([array of MethodListItem](https://docs.fous.com/api-reference/methods.md#the-methodlistitem-object), required)

### Example request

```bash
curl 'https://api.fous.com/v1/methods' \
  -H "Authorization: Bearer $FOUS_API_KEY"
```

With every optional parameter:

```bash
curl 'https://api.fous.com/v1/methods?platform=crates.io&ids=mth_01m5kz9a1b2c3d4e5f6g7h8j9k' \
  -H "Authorization: Bearer $FOUS_API_KEY"
```

### Response 200

```json
{
  "methods": [
    {
      "id": "mth_01m5kz9a1b2c3d4e5f6g7h8j9k",
      "slug": "crates.io/search_crates",
      "name": "Search crates",
      "description": "Searches crates.io by keyword.",
      "returns": "name, description, downloads, version",
      "platform": {
        "name": "crates.io",
        "domain": "crates.io"
      },
      "input_schema": {
        "type": "object",
        "required": [
          "query"
        ],
        "properties": {
          "query": {
            "type": "string",
            "description": "Keyword."
          }
        }
      },
      "effect": "read",
      "auth": {
        "required": false
      },
      "cost": {
        "credits": 1
      },
      "version": 1,
      "latest_version": 1,
      "private": true,
      "status": "ready",
      "pinned_version": 1,
      "visibility": "private",
      "owned": true,
      "stats": {
        "success_rate": 1,
        "runs": 4,
        "last_success_at": "2026-10-23T09:02:11.000Z"
      },
      "created_at": "2026-10-23T08:41:12.000Z",
      "updated_at": "2026-10-23T08:41:12.000Z"
    }
  ]
}
```

## Get a method

`GET https://api.fous.com/v1/methods/{domain}/{name}` or `GET https://api.fous.com/v1/methods/{id}`

A method’s full contract at the version your organization uses (or @N for one version): input and output schema, an example, auth, cost, how it stands (status, repair), its versions and what the latest changes. With wait, the answer is held while the version is under repair; with seen (the status:revision:deletes_at of the last read) while nothing about it has changed. Free.

### Path parameters

`/v1/methods/{domain}/{name}`:

- `domain` (string, required): The site of the method’s slug.
- `name` (string, required): The name of the method’s slug.

`/v1/methods/{id}`:

- `id` (string, required): The method’s id (mth_…).

### Query parameters

- `wait` (integer): Seconds to hold the answer while the version is under repair (or, with seen, while nothing has changed), 0 to 60. Default 0.
- `seen` (string): What was last read, as <status>:<revision>:<deletes_at or ->; with wait, the answer is held until it differs.

### Returns

A [MethodDetail](https://docs.fous.com/api-reference/methods.md#the-methoddetail-object) object.

- `200`: The method.

### Errors

| Status | Code | When |
| --- | --- | --- |
| 404 | `not_found` | No such method, or no such version of it |

### Example request

```bash
curl 'https://api.fous.com/v1/methods/date.nager.at/list_public_holidays' \
  -H "Authorization: Bearer $FOUS_API_KEY"
```

With every optional parameter:

```bash
curl 'https://api.fous.com/v1/methods/date.nager.at/list_public_holidays?wait=30&seen=repairing%3A2%3A-' \
  -H "Authorization: Bearer $FOUS_API_KEY"
```

### Response 200

```json
{
  "id": "mth_01m5kvvywdeac8fxs7nh0sw68w",
  "slug": "date.nager.at/list_public_holidays",
  "name": "List public holidays",
  "description": "Lists a country's public holidays for a year from Nager.Date, with local names, regional coverage and holiday types.",
  "returns": "date, weekday, English and local names, regions, type, nationwide flag",
  "platform": {
    "name": "Nager.Date",
    "domain": "nager.at"
  },
  "input_schema": {
    "type": "object",
    "required": [
      "country"
    ],
    "properties": {
      "year": {
        "type": "integer",
        "minimum": 1,
        "maximum": 9999,
        "description": "Calendar year, for example 2026. Defaults to the current year."
      },
      "country": {
        "type": "string",
        "description": "Country name or two-letter country code, for example Germany or DE."
      }
    }
  },
  "effect": "read",
  "auth": {
    "required": false
  },
  "cost": {
    "credits": 1
  },
  "version": 2,
  "latest_version": 2,
  "revision": 1,
  "pinned_version": null,
  "status": "ready",
  "versions": [
    {
      "version": 2,
      "revision": 1,
      "latest": true,
      "status": "ready",
      "created_at": "2026-10-22T16:02:41.000Z",
      "changes": "Adds output holidays[].regions."
    },
    {
      "version": 1,
      "revision": 2,
      "status": "ready",
      "created_at": "2026-10-21T09:12:05.000Z",
      "revised_at": "2026-10-24T03:10:19.000Z",
      "changes": ""
    }
  ],
  "visibility": "public",
  "output_schema": {
    "type": "object",
    "properties": {
      "country_name": {
        "type": "string"
      },
      "year": {
        "type": "integer"
      },
      "holidays": {
        "type": "array",
        "items": {
          "type": "object"
        }
      }
    }
  },
  "example": {
    "input": {
      "country": "Germany",
      "year": 2027
    },
    "output": {
      "country_name": "Germany",
      "year": 2027,
      "holidays": [
        {
          "date": "2027-01-01",
          "weekday": "Friday",
          "english_name": "New Year's Day",
          "local_name": "Neujahr",
          "nationwide": "yes",
          "regions": [],
          "type": "Public"
        }
      ]
    }
  },
  "stats": {
    "success_rate": 1,
    "runs": 12,
    "last_success_at": "2026-10-23T08:24:36.410Z"
  },
  "owned": false
}
```

### Error 404

```json
{
  "error": {
    "code": "not_found",
    "message": "No version 9 of date.nager.at/list_public_holidays. Its versions are 1–2.",
    "next_step": "Name one of them (date.nager.at/list_public_holidays@N), or none for the version your organization uses.",
    "param": "method",
    "latest_version": 2,
    "doc_url": "https://docs.fous.com/guides/errors#not_found",
    "request_id": "req_mh7c2k9xQ1v3Zt8LbN0pRwY4"
  }
}
```

## Update a method

`PATCH https://api.fous.com/v1/methods/{domain}/{name}` or `PATCH https://api.fous.com/v1/methods/{id}`

{"pinned_version": N} switches your organization to version N of any method it sees: runs and queries use it from then on. {"visibility": "public"} publishes your organization’s method: anyone may then find, run and improve it; a public method stays public. Owners and admins.

### Path parameters

`/v1/methods/{domain}/{name}`:

- `domain` (string, required): The site of the method’s slug.
- `name` (string, required): The name of the method’s slug.

`/v1/methods/{id}`:

- `id` (string, required): The method’s id (mth_…).

### Request body

Required, JSON. One of:

#### Switch version

- `pinned_version` (integer, required): The version your organization switches to.

#### Publish

- `visibility` (string, required): "public" publishes the method. There is no way back: others may come to rely on it. Must be `public`.

### Returns

A [MethodDetail](https://docs.fous.com/api-reference/methods.md#the-methoddetail-object) object.

- `200`: The method, as your organization now sees it.

### Errors

| Status | Code | When |
| --- | --- | --- |
| 400 | `invalid_request` | Neither {"pinned_version": N} nor {"visibility": "public"} |
| 403 | `forbidden` | Only owners and admins change methods and builds |
| 404 | `not_found` | No such method, or no such version of it |
| 409 | `conflict` | Publishing: not your organization’s method (reason not_owned), or another public method has its name |

### Example request: Switch version

```bash
curl 'https://api.fous.com/v1/methods/date.nager.at/list_public_holidays' \
  -X PATCH \
  -H "Authorization: Bearer $FOUS_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
    "pinned_version": 1
  }'
```

### Example request: Publish

```bash
curl 'https://api.fous.com/v1/methods/date.nager.at/list_public_holidays' \
  -X PATCH \
  -H "Authorization: Bearer $FOUS_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
    "visibility": "public"
  }'
```

### Response 200

```json
{
  "id": "mth_01m5kvvywdeac8fxs7nh0sw68w",
  "slug": "date.nager.at/list_public_holidays",
  "name": "List public holidays",
  "description": "Lists a country's public holidays for a year from Nager.Date, with local names, regional coverage and holiday types.",
  "returns": "date, weekday, English and local names, regions, type, nationwide flag",
  "platform": {
    "name": "Nager.Date",
    "domain": "nager.at"
  },
  "input_schema": {
    "type": "object",
    "required": [
      "country"
    ],
    "properties": {
      "year": {
        "type": "integer",
        "minimum": 1,
        "maximum": 9999,
        "description": "Calendar year, for example 2026. Defaults to the current year."
      },
      "country": {
        "type": "string",
        "description": "Country name or two-letter country code, for example Germany or DE."
      }
    }
  },
  "effect": "read",
  "auth": {
    "required": false
  },
  "cost": {
    "credits": 1
  },
  "version": 1,
  "latest_version": 2,
  "revision": 2,
  "pinned_version": 1,
  "status": "ready",
  "versions": [
    {
      "version": 2,
      "revision": 1,
      "latest": true,
      "status": "ready",
      "created_at": "2026-10-22T16:02:41.000Z",
      "changes": "Adds output holidays[].regions."
    },
    {
      "version": 1,
      "revision": 2,
      "status": "ready",
      "created_at": "2026-10-21T09:12:05.000Z",
      "revised_at": "2026-10-24T03:10:19.000Z",
      "changes": "",
      "pinned": true
    }
  ],
  "visibility": "public",
  "output_schema": {
    "type": "object",
    "properties": {
      "country_name": {
        "type": "string"
      },
      "year": {
        "type": "integer"
      },
      "holidays": {
        "type": "array",
        "items": {
          "type": "object"
        }
      }
    }
  },
  "example": {
    "input": {
      "country": "Germany",
      "year": 2027
    },
    "output": {
      "country_name": "Germany",
      "year": 2027,
      "holidays": [
        {
          "date": "2027-01-01",
          "weekday": "Friday",
          "english_name": "New Year's Day",
          "local_name": "Neujahr",
          "nationwide": "yes",
          "regions": [],
          "type": "Public"
        }
      ]
    }
  },
  "stats": {
    "success_rate": 1,
    "runs": 12,
    "last_success_at": "2026-10-23T08:24:36.410Z"
  },
  "owned": false,
  "latest_changes": "Adds output holidays[].regions."
}
```

### Error 400

```json
{
  "error": {
    "code": "invalid_request",
    "message": "Send {\"pinned_version\": N} to switch your organization to version N, or {\"visibility\": \"public\"} to publish.",
    "doc_url": "https://docs.fous.com/guides/errors#invalid_request",
    "request_id": "req_mh7c2k9xQ1v3Zt8LbN0pRwY4"
  }
}
```

## Delete a method

`DELETE https://api.fous.com/v1/methods/{domain}/{name}` or `DELETE https://api.fous.com/v1/methods/{id}`

Deletes your organization’s private method: it no longer runs, and its versions stay for the record. A public method stays, since others may run it. Owners and admins.

### Path parameters

`/v1/methods/{domain}/{name}`:

- `domain` (string, required): The site of the method’s slug.
- `name` (string, required): The name of the method’s slug.

`/v1/methods/{id}`:

- `id` (string, required): The method’s id (mth_…).

### Returns

- `200`: Deleted.

The answer has these fields:

- `id` (string)
- `deleted` (boolean)

### Errors

| Status | Code | When |
| --- | --- | --- |
| 403 | `forbidden` | Only owners and admins change methods and builds |
| 404 | `not_found` | No such method |
| 409 | `conflict` | A public method, or not your organization’s (reason not_owned) |

### Example request

```bash
curl 'https://api.fous.com/v1/methods/crates.io/search_crates' \
  -X DELETE \
  -H "Authorization: Bearer $FOUS_API_KEY"
```

### Response 200

```json
{
  "id": "mth_01m5kz9a1b2c3d4e5f6g7h8j9k",
  "deleted": true
}
```

### Error 403

```json
{
  "error": {
    "code": "forbidden",
    "message": "Only an owner or admin can change methods.",
    "doc_url": "https://docs.fous.com/guides/errors#forbidden",
    "request_id": "req_mh7c2k9xQ1v3Zt8LbN0pRwY4"
  }
}
```
