All URIs are relative to https://us1.pdfgeneratorapi.com/api/v4
| Method | HTTP request | Description |
|---|---|---|
| getTemplateLibrary | GET /templates/library | Get template library |
| getTemplateLibraryItem | GET /templates/library/{publicId} | Open template from the library |
GetTemplateLibrary200Response getTemplateLibrary(opts)
Get template library
Returns a list of publicly available templates from the template library.
import PDFGeneratorAPI from 'pdf-generator-api-client';
let apiInstance = new PDFGeneratorAPI.TemplateLibraryApi();
let opts = {
'tags': "tags_example" // String | Filter template by tags
};
apiInstance.getTemplateLibrary(opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});| Name | Type | Description | Notes |
|---|---|---|---|
| tags | String | Filter template by tags | [optional] |
No authorization required
- Content-Type: Not defined
- Accept: application/json
InlineObject16 getTemplateLibraryItem(public_id)
Open template from the library
Returns the template definition for a public template identified by its `public_id`.
import PDFGeneratorAPI from 'pdf-generator-api-client';
let apiInstance = new PDFGeneratorAPI.TemplateLibraryApi();
let public_id = "bac8381bce1982e5f6957a0f52371336"; // String | Resource public id
apiInstance.getTemplateLibraryItem(public_id, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});| Name | Type | Description | Notes |
|---|---|---|---|
| public_id | String | Resource public id |
No authorization required
- Content-Type: Not defined
- Accept: application/json