A raffle ticket with the organizer, the list of prizes, the draw date and place, the ticket price, a ticket number, a QR code and a note about the draw. Download the Word file to adapt it to your raffle, then generate a ticket for every number.
Upload the ticket template, then send the structured data to get the finished document. Make sure to replace YOUR_API_KEY with your unique key and YOUR_TEMPLATE_ID with the ID of your template.
Send an array of JSON objects and get one document for each object, returned in a ZIP archive. Use the output_name parameter to customize each filename with the merge tags from your template.
curl -X 'POST' \
'https://api.docugenerate.com/v1/document' \
-H 'Accept: application/json' \
-H 'Authorization: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"template_id": "YOUR_TEMPLATE_ID",
"output_format": ".pdf",
"data": {
"organizer": "Riverbend Community Food Bank",
"raffle_name": "Spring Charity Raffle",
"prizes": [
{
"place": "1st",
"prize": "Weekend for two in Napa Valley"
},
{
"place": "2nd",
"prize": "Espresso machine"
},
{
"place": "3rd",
"prize": "Gourmet gift basket"
}
],
"draw_date": "Sat, May 16, 2027, 7:00 PM",
"draw_place": "Riverbend Community Hall",
"price": "5.00",
"currency": "USD",
"ticket_number": "004217",
"ticket_code": "RB-RAFFLE-2027-004217",
"draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank."
}
}' curl -X 'POST' \
'https://api.docugenerate.com/v1/document' \
-H 'Accept: application/json' \
-H 'Authorization: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"template_id": "YOUR_TEMPLATE_ID",
"output_format": ".pdf",
"single_file": false,
"output_name": "Raffle Ticket [ticket_number]",
"data": [
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004217", "ticket_code": "RB-RAFFLE-2027-004217", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004218", "ticket_code": "RB-RAFFLE-2027-004218", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004219", "ticket_code": "RB-RAFFLE-2027-004219", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004220", "ticket_code": "RB-RAFFLE-2027-004220", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004221", "ticket_code": "RB-RAFFLE-2027-004221", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004222", "ticket_code": "RB-RAFFLE-2027-004222", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004223", "ticket_code": "RB-RAFFLE-2027-004223", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004224", "ticket_code": "RB-RAFFLE-2027-004224", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004225", "ticket_code": "RB-RAFFLE-2027-004225", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." },
{ "organizer": "Riverbend Community Food Bank", "raffle_name": "Spring Charity Raffle", "prizes": [{"place":"1st","prize":"Weekend for two in Napa Valley"},{"place":"2nd","prize":"Espresso machine"},{"place":"3rd","prize":"Gourmet gift basket"}], "draw_date": "Sat, May 16, 2027, 7:00 PM", "draw_place": "Riverbend Community Hall", "price": "5.00", "currency": "USD", "ticket_number": "004226", "ticket_code": "RB-RAFFLE-2027-004226", "draw_note": "Winners are called on the day of the draw. You do not need to be present to win. All proceeds go to the food bank." }
]
}' Questions frequently asked about our ticket templates
Get started with 20 free documents per month and our ready-to-use ticket templates.