RequestDraftPdfUrls
RequestDraftPdfUrls
This endpoint retrieves Draft PDF copies of a Form 1099 for a single recipient or multiple recipients. Request the Draft PDF URLs by providing the RecordId associated with the returns.
GET form1099/requestdraftpdfurl Request Body
| Field | Type | Description |
|---|---|---|
| RecordId | string | A unique identifier generated by TaxBandits when a return is created. Mention the return's RecordId that you want to request draft PDF. |
Response Body
| Field | Type | Description |
|---|---|---|
| RecordId | Guid | Unique identifier of the record |
| RecipientId | Guid | Unique Recipient Identifier generated by TaxBandits |
| PayeeRef | string | An unique identifier for each recipient set by the client. |
| DraftPdfUrl | string | URL of the Draft PDF |
| DraftPdfPath | string | Storage path of the draft PDF |
| Errors | object[] | Shows detailed error information |
| Id | string | Returns the validation error code |
| Name | string | Name of the validation error |
| Message | string | Description of the validation error |
Payload

Go Lang
Node.js
Python
.NET C#

Ruby
Java

cURL
Request Params
| Sample | Description | Action |
|---|---|---|
| Sample 1 | Query Params - Request Draft PDF URLs for generated Form 1099 returns using RecordId. |
Sample 1
form1099/requestdraftpdfurl?RecordId=9e47bb81-4fe0-4ef9-878a-a136c5cd0033
Response JSON
| Response | Description | Action |
|---|---|---|
| 200 | Success Response - This is a sample response for successful API requests. | |
| 400 | Bad Request Response - You'll get the below response when your API requests contain any validation errors. | |
| 401 | Unauthorized Response - You'll get the below response when your API requests don't contain valid authentication credentials. |
Response: 200
{
"RecordId": "9e47bb81-4fe0-4ef9-878a-a136c5cd0033",
"RecipientId": "bcf7a877-c6d3-41a4-a67b-65487b1a99c9",
"PayeeRef": "Pe7634",
"DraftPdfUrl": "https://expressirsforms.com.s3.us-east-1.amazonaws.com/pdfs/2f44c904-024f-4f82-80ac-224657826b35/8148f2d3-6cdd-449b-89bb-f357340e2523/1099/12564312/d/Single_Draft.pdf",
"DraftPdfPath": "pdfs/2f44c904-024f-4f82-80ac-224657826b35/8148f2d3-6cdd-449b-89bb-f357340e2523/1099/12564312/d/Single_Draft.pdf",
"Error": null
}
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
url := "<APIURL>/v2.0.0/form1099/requestdraftpdfurl?recordid=9e47bb81-4fe0-4ef9-878a-a136c5cd0033"
method := "GET"
// GET request does not require a request body
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Authorization", "<ACCESS_TOKEN>")
client := &http.Client{}
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := io.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}
const axios = require('axios');
let data = '';
let config = {
method: 'get',
maxBodyLength: Infinity,
url: '<APIURL>/v2.0.0/form1099/requestdraftpdfurl?recordid=9e47bb81-4fe0-4ef9-878a-a136c5cd0033',
headers: {
'Content-Type': 'application/json',
'Authorization': '<ACCESS_TOKEN>'
},
data : data
};
axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
import http.client
import json
conn = http.client.HTTPSConnection("<APIURL>")
payload = ''
headers = {
'Content-Type': 'application/json',
'Authorization': '<ACCESS_TOKEN>'
}
conn.request("GET", "/v2.0.0/form1099/requestdraftpdfurl?recordid=9e47bb81-4fe0-4ef9-878a-a136c5cd0033", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, "<APIURL>/v2.0.0/form1099/requestdraftpdfurl?recordid=9e47bb81-4fe0-4ef9-878a-a136c5cd0033");
request.Headers.Add("Authorization", "<ACCESS_TOKEN>");
var content = new StringContent("", null, "application/json");
request.Content = content;
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
require "uri"
require "json"
require "net/http"
url = URI("<APIURL>/v2.0.0/form1099/requestdraftpdfurl?recordid=9e47bb81-4fe0-4ef9-878a-a136c5cd0033")
http = Net::HTTP.new(url.host, url.port);
request = Net::HTTP::Get.new(url)
request["Content-Type"] = "application/json"
request["Authorization"] = "<ACCESS_TOKEN>"
response = http.request(request)
puts response.read_body
OkHttpClient client = new OkHttpClient().newBuilder()
.build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
.url("<APIURL>/v2.0.0/form1099/requestdraftpdfurl?recordid=9e47bb81-4fe0-4ef9-878a-a136c5cd0033")
.method("GET", body)
.addHeader("Content-Type", "application/json")
.addHeader("Authorization", "<ACCESS_TOKEN>")
.build();
Response response = client.newCall(request).execute();
curl --location '<APIURL>/v2.0.0/form1099/requestdraftpdfurl?recordid=9e47bb81-4fe0-4ef9-878a-a136c5cd0033' --header 'Content-Type: application/json' --header 'Authorization: <ACCESS_TOKEN>' --data ''