> For the complete documentation index, see [llms.txt](https://docs.violet.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.violet.io/prism/merchants/configuration/availability-rules.md).

# Availability rules

An availability rule controls whether products matching a tag can be purchased. It applies to matching offers, new and existing, as each product syncs: read [How catalog rules work](/prism/merchants/configuration/how-catalog-rules-work.md) first if you have not.

{% hint style="warning" %}
Availability rules match on tags only. A rule keyed by vendor is accepted and stored, but has no effect.
{% endhint %}

## What the rule does

Availability is purchasability only. A rule with `available` set to `false` makes every matching product unpurchasable: the offer's status becomes unavailable and every SKU under it follows. The products stay visible in the catalog and can still be browsed. The rule changes what a shopper can do, not what a shopper can see.

`available: true` is not the same as removing the rule. It forces matching products to be purchasable even where they otherwise would not be, such as draft products, products hidden on the merchant's platform, or products another availability rule marks unavailable. A product matching one rule set to `true` and another set to `false` ends up purchasable. SKUs with tracked inventory and no stock still show as out of stock.

To return matching products to their normal status, delete the rule.

## Every rule states its effect explicitly

There is no neutral availability rule. A rule either forces matching products to be purchasable or makes them unpurchasable, and the `available` field is what says which. To have no effect, delete the rule.

{% hint style="danger" %}
The write is a literal `PUT`: the request body replaces the entire rule, and an omitted `available` field is not preserved from the previous value. A rule written without `available` is stored with `available: false`, which makes every matching product unpurchasable. Always include `available` explicitly in every write.
{% endhint %}

{% hint style="warning" %}
The `published` field on this rule is deprecated: it appears in the schema but has no effect and nothing reads it. Omit it.
{% endhint %}

## Example

Make every product tagged `final-sale` unpurchasable while leaving it browsable in the catalog:

```
PUT /merchants/{merchant_id}/catalog-rules/availability/tags/final-sale
```

```json
{
  "available": false
}
```

Delete the rule to remove the override:

```
DELETE /merchants/{merchant_id}/catalog-rules/availability/tags/final-sale
```

All rules for a merchant, both types, are readable in one call via `GET /merchants/{merchant_id}/catalog-rules`. Endpoint details are in [Merchant Configuration Resources](/prism/merchants/merchant-configuration-resources.md#catalog-rules).

## Related

* [How catalog rules work](/prism/merchants/configuration/how-catalog-rules-work.md) explains when availability applies relative to exclusion.
* [Exclusion rules](/prism/merchants/configuration/exclusion-rules.md) act earlier, before products enter the catalog.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.violet.io/prism/merchants/configuration/availability-rules.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
