credit_note.created
curl --request POST \
--url https://us.api.flexprice.io/v1/webhook-events/credit_note.createdimport requests
url = "https://us.api.flexprice.io/v1/webhook-events/credit_note.created"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://us.api.flexprice.io/v1/webhook-events/credit_note.created', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://us.api.flexprice.io/v1/webhook-events/credit_note.created",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://us.api.flexprice.io/v1/webhook-events/credit_note.created"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://us.api.flexprice.io/v1/webhook-events/credit_note.created")
.asString();require 'uri'
require 'net/http'
url = URI("https://us.api.flexprice.io/v1/webhook-events/credit_note.created")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body{
"credit_note": {
"credit_note_number": "<string>",
"credit_note_status": "DRAFT",
"credit_note_type": "ADJUSTMENT",
"currency": "<string>",
"customer_id": "<string>",
"finalized_at": "2023-11-07T05:31:56Z",
"id": "<string>",
"invoice_id": "<string>",
"memo": "<string>",
"metadata": {},
"reason": "DUPLICATE",
"subscription_id": "<string>",
"total_amount": "<string>",
"voided_at": "2023-11-07T05:31:56Z"
},
"event_type": "subscription.created"
}Webhook Events
credit_note.created
Fired when a new credit note is created. Doc-only for parsing.
POST
/
webhook-events
/
credit_note.created
credit_note.created
curl --request POST \
--url https://us.api.flexprice.io/v1/webhook-events/credit_note.createdimport requests
url = "https://us.api.flexprice.io/v1/webhook-events/credit_note.created"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://us.api.flexprice.io/v1/webhook-events/credit_note.created', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://us.api.flexprice.io/v1/webhook-events/credit_note.created",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://us.api.flexprice.io/v1/webhook-events/credit_note.created"
req, _ := http.NewRequest("POST", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://us.api.flexprice.io/v1/webhook-events/credit_note.created")
.asString();require 'uri'
require 'net/http'
url = URI("https://us.api.flexprice.io/v1/webhook-events/credit_note.created")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
response = http.request(request)
puts response.read_body{
"credit_note": {
"credit_note_number": "<string>",
"credit_note_status": "DRAFT",
"credit_note_type": "ADJUSTMENT",
"currency": "<string>",
"customer_id": "<string>",
"finalized_at": "2023-11-07T05:31:56Z",
"id": "<string>",
"invoice_id": "<string>",
"memo": "<string>",
"metadata": {},
"reason": "DUPLICATE",
"subscription_id": "<string>",
"total_amount": "<string>",
"voided_at": "2023-11-07T05:31:56Z"
},
"event_type": "subscription.created"
}Response
200 - application/json
Webhook payload
Show child attributes
Show child attributes
Available options:
subscription.created, subscription.draft.created, subscription.activated, subscription.updated, subscription.paused, subscription.cancelled, subscription.resumed, subscription.plan_changed, subscription.phase.created, subscription.phase.updated, subscription.phase.deleted, feature.created, feature.updated, feature.deleted, feature.wallet_balance.alert, entitlement.created, entitlement.updated, entitlement.deleted, wallet.created, wallet.updated, wallet.terminated, wallet.transaction.created, wallet.transaction.updated, payment.created, payment.updated, payment.failed, payment.success, payment.pending, customer.created, customer.updated, customer.deleted, invoice.update.finalized, invoice.update.payment, invoice.update.voided, invoice.update, invoice.payment.overdue, wallet.credit_balance.dropped, wallet.credit_balance.recovered, wallet.ongoing_balance.dropped, wallet.ongoing_balance.recovered, wallet.ongoing_balance.updated, subscription.spend.threshold_reached, subscription.spend.threshold_recovered, subscription.line_item_spend.threshold_reached, subscription.line_item_spend.threshold_recovered, subscription.group_spend.threshold_reached, subscription.group_spend.threshold_recovered, entitlement.grant.exhausted, subscription.renewal.due, invoice.communication.triggered, credit_note.created, credit_note.updated, checkout.session.initiated, checkout.session.completed, checkout.session.failed, checkout.session.expired, event.rejected 
