Kiwify - Subscription
Eventos da família subscription.* na integração Kiwify.
Eventos Disponíveis
subscription.activesubscription.canceledsubscription.past_due
Estrutura do Payload
{ "event": "subscription_active", "subscription_id": "SUB-456", "order_id": "ORDER-123", "status": "active", "created_at": "2024-01-15T10:30:00", "payment_method": "credit_card", "product_id": "PROD-001", "product_name": "Plano Mensal", "product_type": "subscription_plan", "Subscription": { "status": "active", "start_date": "2024-01-15T10:30:00", "next_payment": "2024-02-15T10:30:00", "plan": { "name": "Plano Mensal" }, "charges": { "completed": [{ "order_id": "ORDER-123" }] } }, "Commissions": { "currency": "BRL", "charge_amount": 4970, "product_base_price": 4970 }, "Customer": { "full_name": "João Silva", "CPF": "12345678900", "mobile": "5511999999999", "ip": "192.168.1.1" }, "TrackingParameters": { "src": "facebook", "utm_source": "facebook" }}Componentes do Payload
Customer
| Campo | Tipo | Descrição |
|---|---|---|
id | null | Sempre null |
name | string | null | Nome completo do cliente |
email | string | null | E-mail do cliente |
document | string | null | CPF ou CNPJ |
phone_numbers | Collection | Coleção de telefones |
address | Address | Endereço do cliente |
Telefone
| Campo | Tipo | Descrição |
|---|---|---|
formatted_phone | string | null | Telefone formatado |
type | null | Sempre null |
raw_number | string | null | Número bruto |
area_code | null | Sempre null |
international_dialing_code | null | Sempre null |
Endereço
| Campo | Tipo | Descrição |
|---|---|---|
street | string | null | Rua |
number | string | null | Número |
complement | string | null | Complemento |
neighborhood | string | null | Bairro |
city | string | null | Cidade |
state | string | null | Estado |
country | string | null | País |
postal_code | string | null | CEP |
Subscription
| Campo | Tipo | Descrição |
|---|---|---|
id | string | null | ID da assinatura |
name | string | null | Nome do plano |
created_at | integer | null | Timestamp de início |
updated_at | null | Sempre null |
canceled_at | null | Sempre null |
cancellation_reason | null | Sempre null |
charged_times | integer | Número de cobranças completadas |
current_cycle | integer | Ciclo atual da assinatura |
current_cycle_start | null | Sempre null |
current_cycle_end | integer | null | Timestamp do próximo pagamento |
status | string | Status normalizado da assinatura |
Status Normalizados (SubscriptionStatus)
A Kiwify retorna os seguintes valores normalizados para o status da assinatura:
| Valor | Descrição |
|---|---|
active | Ativa |
canceled | Cancelada |
past_due | Pagamento atrasado |
paused | Pausada |
Payment
| Campo | Tipo | Descrição |
|---|---|---|
currency | string | Moeda (BRL) |
total | integer | Valor total (em centavos) |
discount_value | null | Sempre null |
shipping_value | null | Sempre null |
total_products_value | integer | Valor base dos produtos (em centavos) |
payment_method | PaymentMethod | Método de pagamento |
coupons | Collection | Coleção de cupons (vazia) |
Métodos de Pagamento (PaymentMethod)
A Kiwify retorna os seguintes métodos de pagamento:
| Valor | Descrição |
|---|---|
credit_card | Cartão de Crédito |
pix | PIX |
boleto | Boleto Bancário |
Product
| Campo | Tipo | Descrição |
|---|---|---|
id | string | null | ID do produto |
name | string | null | Nome do produto |
quantity | integer | Sempre 1 |
unit_value | integer | Valor unitário (em centavos) |
total_value | integer | Valor total (em centavos) |
image_url | null | Sempre null |
type | string | Tipo do produto (product ou subscription_plan) |
offer_type | string | Sempre main |
Checkout
| Campo | Tipo | Descrição |
|---|---|---|
id | null | Sempre null |
url | null | Sempre null |
Lead Tracking
| Campo | Tipo | Descrição |
|---|---|---|
src | string | null | Fonte do tracking |
sck | string | null | SCK |
utm_source | string | null | UTM Source |
utm_campaign | string | null | UTM Campaign |
utm_medium | string | null | UTM Medium |
utm_content | string | null | UTM Content |
utm_term | string | null | UTM Term |
utm_id | null | Sempre null |
meta_fbp | null | Sempre null |
google_ga_id | null | Sempre null |
google_gclid | null | Sempre null |
google_gclsrc | null | Sempre null |
google_dclid | null | Sempre null |
google_gbraid | null | Sempre null |
google_wbraid | null | Sempre null |
tiktok_ttlid | null | Sempre null |
ip | string | null | Endereço IP do cliente |
Charge (vazio)
| Campo | Tipo | Descrição |
|---|---|---|
id | null | Sempre null |
created_at | null | Sempre null |
status | null | Sempre null |
type | null | Sempre null |
value | null | Sempre null |
[!NOTE] Essa integração não disponibiliza informações de cobrança.