---
title: "POST /v4/config/decode/{distributionChainId}"
method: POST
path: "/v4/config/decode/{distributionChainId}"
tags: ["Config"]
---

# POST /v4/config/decode/{distributionChainId}

`POST /v4/config/decode/{distributionChainId}`

Decodes campaign data from the Distribution contract. Use distributionChainId path parameter and provide on-chain campaign data in body.

## Path parameters

- `distributionChainId` union, required
  - string, numeric
  - number

## Request body

- object — On-chain campaign data fetched from the Distribution contract
  - `campaignId` string, required
  - `creator` string, required — Address
  - `rewardToken` string, required — Address
  - `amount` string, required
  - `campaignType` integer, required
  - `startTimestamp` number, required — Unix timestamp in seconds (not milliseconds).
  - `duration` integer, required
  - `campaignData` string, required

## Response `200`

Response for status 200

- unknown

## Changes

- **2026-09-02** `b7784c9a78b9` — 6 warning
  - changed the pattern of the request property `creator` from `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55})$` to `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55}|0x[a-fA-F0-9]{64})$` (media type: application/json)
  - changed the pattern of the request property `creator` from `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55})$` to `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55}|0x[a-fA-F0-9]{64})$` (media type: application/x-www-form-urlencoded)
  - changed the pattern of the request property `creator` from `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55})$` to `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55}|0x[a-fA-F0-9]{64})$` (media type: multipart/form-data)
  - changed the pattern of the request property `rewardToken` from `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55})$` to `^(0x[a-fA-F0-9]{40}|[1-9A-HJ-NP-Za-km-z]{32,44}|[CG][A-Z0-9]{55}|0x[a-fA-F0-9]{64})$` (media type: application/json)
  - …2 more

[Change history](https://skmtc.dev/merkl/apis/merkl-api/changes/v4/config/decode/:distributionChainId/post.md)

---

[API](https://skmtc.dev/merkl/apis/merkl-api.md) · [All operations](https://skmtc.dev/merkl/apis/merkl-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/merkl/merkl-api/revisions/b7784c9a78b9/schema)
