Customer Blocklist
Add Blocklist Note
Add a note to a blocklist entry.
POST
/
blocklist
/
customers
/
{entry_id}
/
notes
JavaScript
import DodoPayments from 'dodopayments';
const client = new DodoPayments({
bearerToken: process.env['DODO_PAYMENTS_API_KEY'], // This is the default and can be omitted
});
const blockedCustomerNote = await client.blocklist.customers.notes.create('entry_id', {
note: 'note',
});
console.log(blockedCustomerNote.id);import os
from dodopayments import DodoPayments
client = DodoPayments(
bearer_token=os.environ.get("DODO_PAYMENTS_API_KEY"), # This is the default and can be omitted
)
blocked_customer_note = client.blocklist.customers.notes.create(
entry_id="entry_id",
note="note",
)
print(blocked_customer_note.id)package main
import (
"context"
"fmt"
"github.com/dodopayments/dodopayments-go"
"github.com/dodopayments/dodopayments-go/option"
)
func main() {
client := dodopayments.NewClient(
option.WithBearerToken("My Bearer Token"),
)
blockedCustomerNote, err := client.Blocklist.Customers.Notes.New(
context.TODO(),
"entry_id",
dodopayments.BlocklistCustomerNoteNewParams{
NoteRequest: dodopayments.NoteRequestParam{
Note: dodopayments.F("note"),
},
},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", blockedCustomerNote.ID)
}
package com.dodopayments.api.example;
import com.dodopayments.api.client.DodoPaymentsClient;
import com.dodopayments.api.client.okhttp.DodoPaymentsOkHttpClient;
import com.dodopayments.api.models.blocklist.customers.notes.BlockedCustomerNote;
import com.dodopayments.api.models.blocklist.customers.notes.NoteCreateParams;
import com.dodopayments.api.models.blocklist.customers.notes.NoteRequest;
public final class Main {
private Main() {}
public static void main(String[] args) {
DodoPaymentsClient client = DodoPaymentsOkHttpClient.fromEnv();
NoteCreateParams params = NoteCreateParams.builder()
.entryId("entry_id")
.noteRequest(NoteRequest.builder()
.note("note")
.build())
.build();
BlockedCustomerNote blockedCustomerNote = client.blocklist().customers().notes().create(params);
}
}package com.dodopayments.api.example
import com.dodopayments.api.client.DodoPaymentsClient
import com.dodopayments.api.client.okhttp.DodoPaymentsOkHttpClient
import com.dodopayments.api.models.blocklist.customers.notes.BlockedCustomerNote
import com.dodopayments.api.models.blocklist.customers.notes.NoteCreateParams
import com.dodopayments.api.models.blocklist.customers.notes.NoteRequest
fun main() {
val client: DodoPaymentsClient = DodoPaymentsOkHttpClient.fromEnv()
val params: NoteCreateParams = NoteCreateParams.builder()
.entryId("entry_id")
.noteRequest(NoteRequest.builder()
.note("note")
.build())
.build()
val blockedCustomerNote: BlockedCustomerNote = client.blocklist().customers().notes().create(params)
}require "dodopayments"
dodo_payments = Dodopayments::Client.new(
bearer_token: "My Bearer Token",
environment: "test_mode" # defaults to "live_mode"
)
blocked_customer_note = dodo_payments.blocklist.customers.notes.create("entry_id", note: "note")
puts(blocked_customer_note)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Dodopayments\Client;
use Dodopayments\Core\Exceptions\APIException;
$client = new Client(
bearerToken: getenv('DODO_PAYMENTS_API_KEY') ?: 'My Bearer Token',
environment: 'test_mode',
);
try {
$blockedCustomerNote = $client->blocklist->customers->notes->create(
'entry_id', note: 'note'
);
var_dump($blockedCustomerNote);
} catch (APIException $e) {
echo $e->getMessage();
}using System;
using DodoPayments.Client;
using DodoPayments.Client.Models.Blocklist.Customers.Notes;
DodoPaymentsClient client = new();
NoteCreateParams parameters = new()
{
EntryID = "entry_id",
Note = "note",
};
var blockedCustomerNote = await client.Blocklist.Customers.Notes.Create(parameters);
Console.WriteLine(blockedCustomerNote);use dodopayments::Client;
#[tokio::main]
async fn main() -> dodopayments::Result<()> {
let client = Client::from_env()?;
let entry_id = "entry_id";
let result = client
.blocklist()
.customers()
.notes()
.create()
.entry_id(entry_id)
.body(dodopayments::models::BlocklistCustomersNotesCreateParams {
note: Some("note".to_string()),
..Default::default()
})
.await?;
println!("{result:?}");
Ok(())
}curl --request POST \
--url https://test.dodopayments.com/blocklist/customers/{entry_id}/notes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"note": "<string>"
}
'{
"created_at": "2023-11-07T05:31:56Z",
"id": "<string>",
"note": "<string>",
"author_email": "<string>",
"updated_at": "2023-11-07T05:31:56Z"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Blocklist entry id
Body
application/json
Last modified on October 28, 2026
Was this page helpful?
⌘I
JavaScript
import DodoPayments from 'dodopayments';
const client = new DodoPayments({
bearerToken: process.env['DODO_PAYMENTS_API_KEY'], // This is the default and can be omitted
});
const blockedCustomerNote = await client.blocklist.customers.notes.create('entry_id', {
note: 'note',
});
console.log(blockedCustomerNote.id);import os
from dodopayments import DodoPayments
client = DodoPayments(
bearer_token=os.environ.get("DODO_PAYMENTS_API_KEY"), # This is the default and can be omitted
)
blocked_customer_note = client.blocklist.customers.notes.create(
entry_id="entry_id",
note="note",
)
print(blocked_customer_note.id)package main
import (
"context"
"fmt"
"github.com/dodopayments/dodopayments-go"
"github.com/dodopayments/dodopayments-go/option"
)
func main() {
client := dodopayments.NewClient(
option.WithBearerToken("My Bearer Token"),
)
blockedCustomerNote, err := client.Blocklist.Customers.Notes.New(
context.TODO(),
"entry_id",
dodopayments.BlocklistCustomerNoteNewParams{
NoteRequest: dodopayments.NoteRequestParam{
Note: dodopayments.F("note"),
},
},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", blockedCustomerNote.ID)
}
package com.dodopayments.api.example;
import com.dodopayments.api.client.DodoPaymentsClient;
import com.dodopayments.api.client.okhttp.DodoPaymentsOkHttpClient;
import com.dodopayments.api.models.blocklist.customers.notes.BlockedCustomerNote;
import com.dodopayments.api.models.blocklist.customers.notes.NoteCreateParams;
import com.dodopayments.api.models.blocklist.customers.notes.NoteRequest;
public final class Main {
private Main() {}
public static void main(String[] args) {
DodoPaymentsClient client = DodoPaymentsOkHttpClient.fromEnv();
NoteCreateParams params = NoteCreateParams.builder()
.entryId("entry_id")
.noteRequest(NoteRequest.builder()
.note("note")
.build())
.build();
BlockedCustomerNote blockedCustomerNote = client.blocklist().customers().notes().create(params);
}
}package com.dodopayments.api.example
import com.dodopayments.api.client.DodoPaymentsClient
import com.dodopayments.api.client.okhttp.DodoPaymentsOkHttpClient
import com.dodopayments.api.models.blocklist.customers.notes.BlockedCustomerNote
import com.dodopayments.api.models.blocklist.customers.notes.NoteCreateParams
import com.dodopayments.api.models.blocklist.customers.notes.NoteRequest
fun main() {
val client: DodoPaymentsClient = DodoPaymentsOkHttpClient.fromEnv()
val params: NoteCreateParams = NoteCreateParams.builder()
.entryId("entry_id")
.noteRequest(NoteRequest.builder()
.note("note")
.build())
.build()
val blockedCustomerNote: BlockedCustomerNote = client.blocklist().customers().notes().create(params)
}require "dodopayments"
dodo_payments = Dodopayments::Client.new(
bearer_token: "My Bearer Token",
environment: "test_mode" # defaults to "live_mode"
)
blocked_customer_note = dodo_payments.blocklist.customers.notes.create("entry_id", note: "note")
puts(blocked_customer_note)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Dodopayments\Client;
use Dodopayments\Core\Exceptions\APIException;
$client = new Client(
bearerToken: getenv('DODO_PAYMENTS_API_KEY') ?: 'My Bearer Token',
environment: 'test_mode',
);
try {
$blockedCustomerNote = $client->blocklist->customers->notes->create(
'entry_id', note: 'note'
);
var_dump($blockedCustomerNote);
} catch (APIException $e) {
echo $e->getMessage();
}using System;
using DodoPayments.Client;
using DodoPayments.Client.Models.Blocklist.Customers.Notes;
DodoPaymentsClient client = new();
NoteCreateParams parameters = new()
{
EntryID = "entry_id",
Note = "note",
};
var blockedCustomerNote = await client.Blocklist.Customers.Notes.Create(parameters);
Console.WriteLine(blockedCustomerNote);use dodopayments::Client;
#[tokio::main]
async fn main() -> dodopayments::Result<()> {
let client = Client::from_env()?;
let entry_id = "entry_id";
let result = client
.blocklist()
.customers()
.notes()
.create()
.entry_id(entry_id)
.body(dodopayments::models::BlocklistCustomersNotesCreateParams {
note: Some("note".to_string()),
..Default::default()
})
.await?;
println!("{result:?}");
Ok(())
}curl --request POST \
--url https://test.dodopayments.com/blocklist/customers/{entry_id}/notes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"note": "<string>"
}
'{
"created_at": "2023-11-07T05:31:56Z",
"id": "<string>",
"note": "<string>",
"author_email": "<string>",
"updated_at": "2023-11-07T05:31:56Z"
}