GSTR-2A CDN
curl --request GET \
--url https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month} \
--header 'authorization: <authorization>' \
--header 'x-api-key: <x-api-key>'import requests
url = "https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}"
headers = {
"authorization": "<authorization>",
"x-api-key": "<x-api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {authorization: '<authorization>', 'x-api-key': '<x-api-key>'}
};
fetch('https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}', 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://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"authorization: <authorization>",
"x-api-key: <x-api-key>"
],
]);
$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://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("authorization", "<authorization>")
req.Header.Add("x-api-key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}")
.header("authorization", "<authorization>")
.header("x-api-key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["authorization"] = '<authorization>'
request["x-api-key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"code": 200,
"data": {
"data": {
"cdn": [
{
"cfs": "Y",
"cfs3b": "Y",
"ctin": "07ABCCA9123A1YZ",
"fldtr1": "11-Jan-24",
"flprdr1": "Dec-23",
"nt": [
{
"chksum": "62e70374990b3cef19e36d4eee08cd033c63811ddbf7d27601b9a4b83786dbf1",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4a2fc97799229784bd7e98f57109db58f5cb674f534618c9e2fde51",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 561.05,
"rt": 18,
"samt": 0,
"txval": 3116.94
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103340",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 3677.99
},
{
"chksum": "c9cf8df2a4ebb548eeed7c373e6e4760416dc13520de43a1b26f4036f83d2a73",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4eb8bbc314c0ef223d54402ebf09a4368735bb3bdc2159994de0543",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 961.11,
"rt": 18,
"samt": 0,
"txval": 5339.48
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103368",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 6300.59
},
{
"chksum": "fd69021e1d2e13e5044855accbaaae6c9b770a0a7330f30f9c9fb5a70914c587",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4a2b71831e89eba6742a7035660560559843936076fd0466cb6e2c2",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 46380.95,
"rt": 18,
"samt": 0,
"txval": 257671.97
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103394",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 304052.92
},
{
"chksum": "9d01418f52927eae3b7439571a395472876b28d91ac0c75e0c3014e7587023e4",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4fca1a9feeac080875d8fbcb0b2367c00b582c60485119a375ce80f",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 17349.93,
"rt": 18,
"samt": 0,
"txval": 96388.48
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103426",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 113738.41
},
{
"chksum": "ac2f16c2039f07d75db508c9acfe448cd177963a08ad8228e28cbd066ebad18b",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4a50837c18b84b9cc52a5c6423b4afa05dcbf1454ef98aa88206d5d",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 17533.22,
"rt": 18,
"samt": 0,
"txval": 97406.76
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103435",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 114939.98
}
]
}
]
},
"status_cd": "1"
},
"timestamp": 1763446641000,
"transaction_id": "f44b271e-fff6-45dd-ab62-d9c224a623e8"
}GSTR-2A CDN
Get all credit/debit notes in GSTR-2A for a return period for authenticated taxpayer
GET
/
gst
/
compliance
/
tax-payer
/
gstrs
/
gstr-2a
/
cdn
/
{year}
/
{month}
GSTR-2A CDN
curl --request GET \
--url https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month} \
--header 'authorization: <authorization>' \
--header 'x-api-key: <x-api-key>'import requests
url = "https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}"
headers = {
"authorization": "<authorization>",
"x-api-key": "<x-api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {authorization: '<authorization>', 'x-api-key': '<x-api-key>'}
};
fetch('https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}', 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://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"authorization: <authorization>",
"x-api-key: <x-api-key>"
],
]);
$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://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("authorization", "<authorization>")
req.Header.Add("x-api-key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}")
.header("authorization", "<authorization>")
.header("x-api-key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.co.in/gst/compliance/tax-payer/gstrs/gstr-2a/cdn/{year}/{month}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["authorization"] = '<authorization>'
request["x-api-key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"code": 200,
"data": {
"data": {
"cdn": [
{
"cfs": "Y",
"cfs3b": "Y",
"ctin": "07ABCCA9123A1YZ",
"fldtr1": "11-Jan-24",
"flprdr1": "Dec-23",
"nt": [
{
"chksum": "62e70374990b3cef19e36d4eee08cd033c63811ddbf7d27601b9a4b83786dbf1",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4a2fc97799229784bd7e98f57109db58f5cb674f534618c9e2fde51",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 561.05,
"rt": 18,
"samt": 0,
"txval": 3116.94
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103340",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 3677.99
},
{
"chksum": "c9cf8df2a4ebb548eeed7c373e6e4760416dc13520de43a1b26f4036f83d2a73",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4eb8bbc314c0ef223d54402ebf09a4368735bb3bdc2159994de0543",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 961.11,
"rt": 18,
"samt": 0,
"txval": 5339.48
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103368",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 6300.59
},
{
"chksum": "fd69021e1d2e13e5044855accbaaae6c9b770a0a7330f30f9c9fb5a70914c587",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4a2b71831e89eba6742a7035660560559843936076fd0466cb6e2c2",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 46380.95,
"rt": 18,
"samt": 0,
"txval": 257671.97
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103394",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 304052.92
},
{
"chksum": "9d01418f52927eae3b7439571a395472876b28d91ac0c75e0c3014e7587023e4",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4fca1a9feeac080875d8fbcb0b2367c00b582c60485119a375ce80f",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 17349.93,
"rt": 18,
"samt": 0,
"txval": 96388.48
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103426",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 113738.41
},
{
"chksum": "ac2f16c2039f07d75db508c9acfe448cd177963a08ad8228e28cbd066ebad18b",
"d_flag": "Y",
"inv_typ": "R",
"irn": "x4dftn9my4a50837c18b84b9cc52a5c6423b4afa05dcbf1454ef98aa88206d5d",
"irngendate": "13-12-2023",
"itms": [
{
"itm_det": {
"camt": 0,
"iamt": 17533.22,
"rt": 18,
"samt": 0,
"txval": 97406.76
},
"num": 1
}
],
"nt_dt": "13-12-2023",
"nt_num": "ACN2324000103435",
"ntty": "C",
"pos": "24",
"rchrg": "N",
"srctyp": "e-Invoice",
"val": 114939.98
}
]
}
]
},
"status_cd": "1"
},
"timestamp": 1763446641000,
"transaction_id": "f44b271e-fff6-45dd-ab62-d9c224a623e8"
}Response body schema
View response body schema
Headers
GST taxpayer access token. For token-generation steps, refer to the Generate Taxpayer Session recipe, then pass the token in the authorization header.
API key for identification
API version
Query Parameters
Filter to fetch data from specified date. E.g., 28/01/2025
Example:
"29/01/2025"
Filter by supplier / counterparty GSTIN
Example:
"{{ctin}}"
Was this page helpful?
āI