POST
Criar regra

Authorizations

Authorization
string
header
required

HTTP Basic com o token como usuário e o secret como senha: curl -u dpz_tk_…:dpz_sk_…. Crie a chave em https://despezzas.com/settings/api-keys.

Body

application/json
category_id
string
required

Categoria a aplicar.

Example:

"b1a2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d"

match_fields
string[]
required

Campos a comparar.

Example:
source_transaction_id
string
required

Lançamento de origem.

Example:

"8f1c2a34-5b6d-4e7f-8a9b-0c1d2e3f4a5b"

apply_to_existing
boolean

Recategoriza os lançamentos existentes que combinam. Padrão: false.

Example:

true

subcategory_id
string | null

Subcategoria a aplicar.

Example:

"d7e8f9a0-b1c2-4d3e-8f4a-5b6c7d8e9f0a"

Response

Sucesso.

rule
object
required
source_transaction_updated
boolean
required

Se o lançamento de origem foi recategorizado.

Example:

true

updated_existing_count
integer
required

Quantos lançamentos existentes foram recategorizados.

Example:

14