TDS Tax Creation API
curl --request POST \
--url https://api.pazy.io/v1.0/taxes/tdsimport requests
url = "https://api.pazy.io/v1.0/taxes/tds"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://api.pazy.io/v1.0/taxes/tds', 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.pazy.io/v1.0/taxes/tds",
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://api.pazy.io/v1.0/taxes/tds"
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://api.pazy.io/v1.0/taxes/tds")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.pazy.io/v1.0/taxes/tds")
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_bodyTax APIs
TDS Tax Creation API
Create a TDS tax rate for your organization
TDS Tax Creation API
curl --request POST \
--url https://api.pazy.io/v1.0/taxes/tdsimport requests
url = "https://api.pazy.io/v1.0/taxes/tds"
response = requests.post(url)
print(response.text)const options = {method: 'POST'};
fetch('https://api.pazy.io/v1.0/taxes/tds', 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.pazy.io/v1.0/taxes/tds",
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://api.pazy.io/v1.0/taxes/tds"
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://api.pazy.io/v1.0/taxes/tds")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.pazy.io/v1.0/taxes/tds")
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_bodyAuthentication
All requests require an API key in the request headers. Headers:Authorization: Api-Key YOUR_API_KEY
Content-Type: application/json
Request
Content-Type:application/json
Creates a custom TDS rate in your organization tax master. Use the returned id as tdsId when creating vendor advances or other transactions that need a TDS deduction.
To list rates that already exist, use the TDS Taxes API.
Body Parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
name | string | Yes | 1–255 characters | Display name for the rate in Pazy (returned as label on list) |
section | string | Yes | Valid TDS section id from the Pazy tax catalog (e.g. 194C1, 1023, 194J1) | Section the deduction applies under — same ids used when creating rates in the Pazy UI |
rate | number | Yes | 0–100 | Deduction percentage |
Code Examples
curl -X POST https://api.pazy.io/v1.0/taxes/tds \
-H "Authorization: Api-Key YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "TDS 194C 1%",
"section": "194C1",
"rate": 1
}'
const response = await fetch('https://api.pazy.io/v1.0/taxes/tds', {
method: 'POST',
headers: {
Authorization: 'Api-Key YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
name: 'TDS 194C 1%',
section: '194C1',
rate: 1
})
});
const result = await response.json();
import requests
url = "https://api.pazy.io/v1.0/taxes/tds"
headers = {
"Authorization": "Api-Key YOUR_API_KEY",
"Content-Type": "application/json"
}
payload = {
"name": "TDS 194C 1%",
"section": "194C1",
"rate": 1
}
response = requests.post(url, headers=headers, json=payload)
result = response.json()
Success Response
HTTP Status:200 OK
Response Fields:
| Field | Type | Description |
|---|---|---|
ok | boolean | Indicates whether the request was successful |
data.tax.id | string | Tax id. Pass this as tdsId to transaction create APIs |
data.tax.label | string | Display name given to the tax |
data.tax.description | string | Description of the TDS section, or - when none is on record |
data.tax.section | string | Income Tax Act section e.g. 194C |
data.tax.rate | number | Deduction percentage |
data.tax.rateType | string | How rate is applied — PERCENTAGE for rates created via this API |
data.tax.dateCreated | string | ISO 8601 timestamp of when the tax was created |
Response Example
{
"ok": true,
"data": {
"tax": {
"id": "5021",
"label": "TDS 194C 1%",
"description": "Payment of contractors HUF/Individual ",
"section": "194C1",
"rate": 1,
"rateType": "PERCENTAGE",
"dateCreated": "2026-09-02T06:45:12.110Z"
}
}
}
Error Responses
Validation Errors
HTTP Status:400 Bad Request
Returned when section is not a recognized TDS section id.
{
"ok": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Unknown TDS section: 999X"
}
}
Authentication Errors
HTTP Status:401 Unauthorized
{
"ok": false,
"error": {
"code": "MISSING_CREDENTIALS",
"message": "Missing Credentials"
}
}
{
"ok": false,
"error": {
"code": "INVALID_API_KEY",
"message": "Invalid API Key"
}
}
Permission Errors
HTTP Status:403 Forbidden
Returned when the API key doesn’t have the Tax resource with the Create action enabled.
{
"ok": false,
"error": {
"code": "INSUFFICIENT_PERMISSIONS",
"message": "Permission check failed - PERMISSION_CHECK_FAILED"
}
}
Server Errors
HTTP Status:500 Internal Server Error
{
"ok": false,
"error": {
"code": "INTERNAL_ERROR",
"message": "An unexpected error occurred"
}
}
Best Practices
- Prefer creating rates once and reusing the returned
idacross transactions rather than creating a duplicate rate per bill - Match
sectionto a catalog id from the Pazy UI / tax master (e.g.194C1,1023) — free-text labels like bare194Care rejected unless they exist as an id - After create, confirm the rate appears on List TDS Taxes before hardcoding the id in downstream jobs
Was this page helpful?