---
title: "Add Pattern (*)"
method: PUT
path: "/patterns/{pattern}"
tags: ["Patterns"]
---

# Add Pattern (*)

`PUT /patterns/{pattern}`

Add a new pattern to watch and force the server to re-sync from a given point. Only blocks discovered from that point will be matched against the new pattern.

This endpoint may not be instantaneous as the forced rollback may only occur after the next block arrives in the indexer. On the main network, this takes usually
no more than 20 seconds. On test networks however where the block density tends to be much lower, this may take longer.

Note also that, very long rollback will take a substantial amount of time to be processed by the server; if the server is shut down while a rollback is ongoing, the
rollback will be aborted and the server will remain where it was, although with the extra pattern added.

## Path parameters

- `pattern` union, required
  - '*'
  - union — A Cardano address or stake address.
    - unknown
    - unknown
    - unknown
    - unknown
  - string — ``` ┏━━━━━━━━━━━┓ ╭───╮ ┏━━━━━━━━━━━━┓ ╾─┫ POLICY_ID ┣─┤ . ├─┫ ASSET_NAME ┣─╼ ┗━━━━━━━━━━━┛ ╰───╯ ┗━━━━━━━━━━━━┛ ``` A policy id (base16-encoded) and an optional asset name (base16-encoded), dot-separated. Examples: - `1220099e5e430475c219518179efc7e6c8289db028904834025d5b086.*` - `1220099e5e430475c219518179efc7e6c8289db028904834025d5b086.08661220099e`
  - string — ``` ┏━━━━━━━━━━━━━━┓ ╭───╮ ┏━━━━━━━━━━━━━━━━┓ ╾─┫ OUTPUT_INDEX ┣─┤ @ ├─┫ TRANSACTION_ID ┣─╼ ┗━━━━━━━━━━━━━━┛ ╰───╯ ┗━━━━━━━━━━━━━━━━┛ ``` An (optional) output index and transaction id (base16-encoded), separated by a `@`. Examples: - `42@35d8340cd6a5d31bf9d09706b92adedf9b1b632e682fdab9fc8865ee3de14e09` - `*@35d8340cd6a5d31bf9d09706b92adedf9b1b632e682fdab9fc8865ee3de14e09`

## Response `200`

OK

## Other responses

- `400` — Bad Request

---

[API](https://skmtc.net/txpipe/apis/kupo.md) · [All operations](https://skmtc.net/txpipe/apis/kupo/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/txpipe/kupo/revisions/33786c4eb0ff/schema)
