Skip to content

Record a conversion: an upgrade or an order in your product, with its value

POST
/api/v1/workspaces/{workspace}/conversions
# REPUTECAST_API_KEY: an API key (rc_live_…) with conversions:create.
# Replace reputecast.example.com with your public URL and your-workspace with your workspace slug.
# Add "click_token" with the rc_click value of the link the reader followed, when you have it.
curl --request POST \
--url https://reputecast.example.com/api/v1/workspaces/your-workspace/conversions \
--header "Authorization: Bearer $REPUTECAST_API_KEY" \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: order-1042' \
--data '{
"name": "Upgraded to Team plan",
"value": "29.00",
"currency": "USD",
"email": "sam.rivera@outlook.com",
"metadata": { "order_id": "1042" }
}'

Permission: conversions:create

Credits the conversion to the last campaign or automation email the reader clicked within the attribution window: by click token (rc_click), else by email address. Answers 202 with how it was matched. Errors: missing_identity, invalid_value, invalid_currency, occurred_at_out_of_range (422), idempotency_key_reused (409), rate_limited (429, with Retry-After). Conversions are logged in Earn › Settings › Attribution, not in the audit log.

workspace
required

Workspace slug

string
/^[a-z0-9][a-z0-9-]{1,62}$/

Workspace slug

Idempotency-Key

Sending the same key again answers with the first conversion instead of recording a second

string
<= 200 characters

Sending the same key again answers with the first conversion instead of recording a second

Media typeapplication/json
object
click_token

The rc_click token from the link the reader followed, if present

string
<= 512 characters
currency
required

ISO 4217: USD, EUR, GBP…

string
<= 8 characters
email

The reader’s address; send it, the click token, or both

string
<= 320 characters
metadata

Your own fields, kept with the conversion

object
key
additional properties
name
required

What happened: “Upgraded to Team plan”

string
>= 1 characters <= 120 characters
occurred_at

When it happened (now when absent): up to 30 days back

string format: date-time
value
required

A decimal string: “29.00”, not 29

Example generated

{
"click_token": "example",
"currency": "example",
"email": "example",
"metadata": {
"additionalProperty": "example"
},
"name": "example",
"occurred_at": "2026-04-15T12:00:00Z",
"value": "example"
}

Accepted

Media typeapplication/json
object
credited
object
id
required
string
kind
required
string
Allowed values: campaign automation
name
required
string
id
required
string
matched
required
string
Allowed values: click_token email none
test
boolean

Example

{
"credited": {
"kind": "campaign"
},
"matched": "click_token"
}

Error

Media typeapplication/problem+json
object
code

Stable error code, e.g. permission_denied

string
detail

A human-readable explanation specific to this occurrence of the problem.

string
errors

Optional list of individual error details

Array<object>
object
location

Where the error occurred, e.g. ‘body.items[3].tags’ or ‘path.thing-id’

string
message

Error message text

string
value

The value at the given location

helpers

Members who hold the missing permission

Array<string>
instance

A URI reference that identifies the specific occurrence of the problem.

string format: uri
meta
object
key
additional properties
permission

The missing permission key

string
status

HTTP status code

integer format: int64
title

A short, human-readable summary of the problem type. This value should not change between occurrences of the error.

string
type

A URI reference to human-readable documentation for the error.

string format: uri
default: about:blank

Example

{
"detail": "Property foo is required but is missing.",
"instance": "https://example.com/error-log/abc123",
"status": 400,
"title": "Bad Request",
"type": "about:blank"
}