Reconcile GSTR-2B Job
curl --request POST \
--url https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation \
--header 'Content-Type: application/json' \
--header 'authorization: <authorization>' \
--header 'x-api-key: <x-api-key>' \
--data '
{
"@entity": "in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request",
"gstin": "24EGCAZ2081S7Z4",
"year": 2023,
"month": 12,
"filing_preference": "monthly",
"reconciliation_criteria": "strict"
}
'import requests
url = "https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation"
payload = {
"@entity": "in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request",
"gstin": "24EGCAZ2081S7Z4",
"year": 2023,
"month": 12,
"filing_preference": "monthly",
"reconciliation_criteria": "strict"
}
headers = {
"authorization": "<authorization>",
"x-api-key": "<x-api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
authorization: '<authorization>',
'x-api-key': '<x-api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
'@entity': 'in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request',
gstin: '24EGCAZ2081S7Z4',
year: 2023,
month: 12,
filing_preference: 'monthly',
reconciliation_criteria: 'strict'
})
};
fetch('https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation', 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://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'@entity' => 'in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request',
'gstin' => '24EGCAZ2081S7Z4',
'year' => 2023,
'month' => 12,
'filing_preference' => 'monthly',
'reconciliation_criteria' => 'strict'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation"
payload := strings.NewReader("{\n \"@entity\": \"in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request\",\n \"gstin\": \"24EGCAZ2081S7Z4\",\n \"year\": 2023,\n \"month\": 12,\n \"filing_preference\": \"monthly\",\n \"reconciliation_criteria\": \"strict\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("authorization", "<authorization>")
req.Header.Add("x-api-key", "<x-api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation")
.header("authorization", "<authorization>")
.header("x-api-key", "<x-api-key>")
.header("Content-Type", "application/json")
.body("{\n \"@entity\": \"in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request\",\n \"gstin\": \"24EGCAZ2081S7Z4\",\n \"year\": 2023,\n \"month\": 12,\n \"filing_preference\": \"monthly\",\n \"reconciliation_criteria\": \"strict\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["authorization"] = '<authorization>'
request["x-api-key"] = '<x-api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"@entity\": \"in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request\",\n \"gstin\": \"24EGCAZ2081S7Z4\",\n \"year\": 2023,\n \"month\": 12,\n \"filing_preference\": \"monthly\",\n \"reconciliation_criteria\": \"strict\"\n}"
response = http.request(request)
puts response.read_body{
"code": 200,
"transaction_id": "d3d19997-c48a-4867-95b9-5a77c3567098",
"data": {
"@entity": "in.co.sandbox.gst.analytics.gstr-2b_reconciliation.job",
"job_id": "d3d19997-c48a-4867-95b9-5a77c3567098",
"gstin": "24EGCAZ2081S7Z4",
"year": 2023,
"month": 12,
"filing_preference": "monthly",
"reconciliation_criteria": "strict",
"status": "created",
"gstr_2b_url": "https://in-co-sandbox-gst-test-storage.s3.ap-south-1.amazonaws.com/gstr-2b-reconciliation/gstr-2b.json",
"purchase_ledger_url": "https://in-co-sandbox-gst-test-storage.s3.ap-south-1.amazonaws.com/gstr-2b-reconciliation/purchase-ledger.json",
"created_at": 123
},
"timestamp": 123
}Submit Job
Submit GSTR-2B reconciliation job and get two signed URLs to upload GSTR-2B and purchase ledger.
POST
/
gst
/
analytics
/
gstr-2b-reconciliation
Reconcile GSTR-2B Job
curl --request POST \
--url https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation \
--header 'Content-Type: application/json' \
--header 'authorization: <authorization>' \
--header 'x-api-key: <x-api-key>' \
--data '
{
"@entity": "in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request",
"gstin": "24EGCAZ2081S7Z4",
"year": 2023,
"month": 12,
"filing_preference": "monthly",
"reconciliation_criteria": "strict"
}
'import requests
url = "https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation"
payload = {
"@entity": "in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request",
"gstin": "24EGCAZ2081S7Z4",
"year": 2023,
"month": 12,
"filing_preference": "monthly",
"reconciliation_criteria": "strict"
}
headers = {
"authorization": "<authorization>",
"x-api-key": "<x-api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
authorization: '<authorization>',
'x-api-key': '<x-api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
'@entity': 'in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request',
gstin: '24EGCAZ2081S7Z4',
year: 2023,
month: 12,
filing_preference: 'monthly',
reconciliation_criteria: 'strict'
})
};
fetch('https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation', 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://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'@entity' => 'in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request',
'gstin' => '24EGCAZ2081S7Z4',
'year' => 2023,
'month' => 12,
'filing_preference' => 'monthly',
'reconciliation_criteria' => 'strict'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation"
payload := strings.NewReader("{\n \"@entity\": \"in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request\",\n \"gstin\": \"24EGCAZ2081S7Z4\",\n \"year\": 2023,\n \"month\": 12,\n \"filing_preference\": \"monthly\",\n \"reconciliation_criteria\": \"strict\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("authorization", "<authorization>")
req.Header.Add("x-api-key", "<x-api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation")
.header("authorization", "<authorization>")
.header("x-api-key", "<x-api-key>")
.header("Content-Type", "application/json")
.body("{\n \"@entity\": \"in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request\",\n \"gstin\": \"24EGCAZ2081S7Z4\",\n \"year\": 2023,\n \"month\": 12,\n \"filing_preference\": \"monthly\",\n \"reconciliation_criteria\": \"strict\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://test-api.sandbox.co.in/gst/analytics/gstr-2b-reconciliation")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["authorization"] = '<authorization>'
request["x-api-key"] = '<x-api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"@entity\": \"in.co.sandbox.gst.analytics.gstr-2b_reconciliation.request\",\n \"gstin\": \"24EGCAZ2081S7Z4\",\n \"year\": 2023,\n \"month\": 12,\n \"filing_preference\": \"monthly\",\n \"reconciliation_criteria\": \"strict\"\n}"
response = http.request(request)
puts response.read_body{
"code": 200,
"transaction_id": "d3d19997-c48a-4867-95b9-5a77c3567098",
"data": {
"@entity": "in.co.sandbox.gst.analytics.gstr-2b_reconciliation.job",
"job_id": "d3d19997-c48a-4867-95b9-5a77c3567098",
"gstin": "24EGCAZ2081S7Z4",
"year": 2023,
"month": 12,
"filing_preference": "monthly",
"reconciliation_criteria": "strict",
"status": "created",
"gstr_2b_url": "https://in-co-sandbox-gst-test-storage.s3.ap-south-1.amazonaws.com/gstr-2b-reconciliation/gstr-2b.json",
"purchase_ledger_url": "https://in-co-sandbox-gst-test-storage.s3.ap-south-1.amazonaws.com/gstr-2b-reconciliation/purchase-ledger.json",
"created_at": 123
},
"timestamp": 123
}This endpoint is part of a job-based async workflow. See the job-based API workflow guide for job creation, payload upload, and status polling.
Upload file schemas
Use these schemas to validate both files before you upload them to the signed URLs returned by this endpoint.View GSTR-2B upload schema
View purchase ledger schema
The GSTR upload schema file lists the available schema versions with their
valid_from dates.Body
application/json