Creates a shorter PDF astrology report, with less birth data requirements.
All fields starting with P1- need to be duplicated and changed to P2- to add a second person for relationship reports.
Request Parameters | ||
---|---|---|
ReportCode | Required | Defines which report is to be created. The ReportCode is part of the service address. /v2/reports/CreateShortPDF/ReportCode/ |
APIKey | Required | A valid API Key for your user account. Provided in setup email |
P1FirstName | Required | First name for person |
P1LastName | Optional | Last name for person |
P1Sex | Required | Single letter code : M for male, F for female |
P1DOB | Required | YYYY-MM-DD format. Add zeros to single digit months or days. Example: 1970-06-27, 2011-12-09 |
OrderID | Optional | Your own order ID, add if you want to track your orders against our billing system. |
TestMode | Optional | Enable test mode by setting field to 1. Test mode allows creation of reports without being billed for the report. |
OutputFormat | Optional | Default response format is set to XML, select JSON by adding outputformat=JSON to any request. |
OutputChoices | Optional | Comma separated list of user selections, used when user is prompted with a list of questions. |
Responses | ||
---|---|---|
ResponseStatus | ||
Code | Code representing errors see result codes to determine the error. | |
Message | Description of the error | |
ResponseData | ||
PDFURL | Link to PDF file, transfer this file to your own server as it will be deleted as the file is temporary. | |
AdditionalData | Extra astrological data included in some reports. |
CreateShortPDF Result codes
Positive result code indicates success, negative shows a failure.
Success Codes
1 OK – Created report
Input Errors – Person 1
-11 Error – Missing first name
-12 Error – Sex not provided or invalid
-13 Error – Missing date of birth
-14 Error – Invalid date of birth
Input Errors – Person 2
-21 Error – Person 2 – Missing first name
-22 Error – Person 2 – Sex not provided or invalid
-23 Error – Person 2 – Missing date of birth
-24 Error – Person 2 – Invalid date of birth
Action Errors
-31 Error – Invalid or Expired ReportID
API Key Errors
-41 Error – Missing API Key
-42 Error – Invalid or expired API Key
System Errors
-91 Error – System error – retry later.
Example Request
Creating a short PDF report for the following birth details:
First Name : John
Last Name : Smith
Sex : Male
Date of Birth : 15th June 1970
In this example PRO-ST-CHART is the ReportCode
/v2/reports/CreateShortPDF/PRO-ST-CHART/?&APIKEY=YOURAPIKEY&P1FirstName=John&P1LastName=Smith&P1Sex=M&P1DOB=1970-06-15
Example Response
<CreateShortPDFResponse>
<ResponseData>
<AdditionalData i:nil = "true"/>
<PDFUrl>https://WEBSERVICEURL/output/uyjlcgls.pdf</PDFUrl>
</ResponseData>
<ResponseStatus>
<Code>1</Code>
<Message>OK - Created report</Message>
</ResponseStatus>
</CreateShortPDFResponse>