Skip to content

Commit

Permalink
new features and postma collection
Browse files Browse the repository at this point in the history
  • Loading branch information
NamanChhabra committed Jul 23, 2024
1 parent c6cbebd commit 88a02e5
Show file tree
Hide file tree
Showing 7 changed files with 110 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/pages/apis/index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Adobe PDF Services Open API spec
description: The OpenAPI spec for Adobe PDF Services API endpoints, parameters, and responses.
openAPISpec: https://raw.githubusercontent.com/AdobeDocs/pdfservices-api-documentation/main/src/pages/resources/openapi.json
openAPISpec: https://raw.githubusercontent.com/AdobeDocs/pdfservices-api-documentation/new_features_and_postmancollection/src/pages/resources/openapi.json
---
12 changes: 11 additions & 1 deletion src/pages/overview/document-generation-api/inlineimages.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ Add inline images in the document through json data using the <img\> tag.

## How It Works

Image url can be provided in the input json data using html img tag.
Image url can be provided in the input json data using html img tag.

Image data can be provided either in the form of the base64 encoded string or in the form of publicly accessible URLs.

JSON representation of the input data:

Expand All @@ -16,6 +18,14 @@ JSON representation of the input data:
"ContentBlock": "sample image - <img src=\"https://documentcloud.adobe.com/dc-docgen-app/assets/dc_icon.png\">"
}
```
<p style="text-align:center;">OR</p>

```json
{
"ContentBlock": "sample image - <img src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAIAAACRXR/mAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAKM0lEQVRYhZVZa4xdVRX+1j7nvmY6fcy0tOC00FKgECgtFLVNBIVoCJBogj9ImviABBDEP0b9gYb6QzEoCgoqGPlBEwiJkqhVoDQmllIeVQiWVJp2lLSh03ZaaWk7M/fec9bnj/04+5x7Z8CTk8w9++yz17fXWvtbj5GDQ3PmUggAaiAADCAi8Jd9J1BEg+4VoCRgADB6SVLdD6FA/biCboLAzsj9iH2lAgBUSSMphlQRUcDQzRYRK4806L0Ih5WkfQRiQJDwSLeOEwy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CBJEmkXvPpkYMSu01aqbpiNwIAEZ2e1nr9nG99s3He8qNPP318x8sf37YtSdI993w9++CUtJp+s8Yv6hojLuTU6wZQ1an9Y8xzAEm9LsYU/To7OXS5ABApwXwm3gI4NZ0sXrx8032ndu06+OMHO8CFmzaddd11Y488cuzPf6k3m/RNmyLaMtidoaUDEanVWEtdZdoPSlAVSflTqzXYDxYFzHM0myvuv//wM898sH07gZEbb/zEli0TO1/ede21Sa5I08gjIxB+gBJp0Zo2hlIRFxayuXweZyChqCfyTmfJxo0nXnv9v9u3E5i7fv26P/7h5N533rj5ZrQ7aLVCZiCwTcCSi7juXQVHVI+WoGgJqwnxIY4SNtTbIJ8Mz5cFC5befvvVO3e+v2vXK9de1z18xLQGlDb9tQmFUErlnq2kM19MR3VzdCttmd8zh/L7ZnMQMctH21VlLR29+655GzYMLV/x3lNP/eehn5l2J2m1vBvFFuuTsbGIVW4OCBHk5Ty40uGhQH7XbM5B0furhGdmWdbtpvPmZadPa56naYpababkugIi4BYRjTo/QUoFCoDQkUoJZrEDViQmiUkSnZw0SWJqNdgkxS8qkY+zqG96PNqhK9VCRdKsoYos2sGpzs5b9tMkKQQGGoAQpAj7Ka+PPlDokSpBZNyyCwlFqsQMdaLvmoloX8khT+8ph+zLqIggaOyIEKHfHGaquNzGNhBApDapnVEqChNY8rAwKtGz2mauhg4p9XajPQGAGE+nBZukdmpoZ/V35ngZKainaHV4TRQuUtYHYxw2VvpNVOpvB8sWwTGzxSt6Xy0pJhJf6oyHnQUXcfKkhANRdx6eSIvPBSTSDKKEImoMRBpTP7WkuKL1TYr7LjiH73sXTl6hJXi/iHDYA2TCNPevKPYwlsPnPLqQHRYFjH2OaGEGEBV9BCg0/iAXlGM9OFUKJQR/Ot0Qft/uPzuR7EJ7vQhiED36QMAhKLFfRYshsQksXzDbLIL7IvClUXwaADUUm+lELFI+NPZ1DIDk/wAgP2EeAXgCoAAAAABJRU5ErkJggg==\">"
}
```

![Representation of sample json data](../images/inlineImageJson.png)

In the above example, the tag <b>ContentBlock</b> contains an <b><img\></b> html tag. This image will be downloaded and placed in the final document as shown below.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ Apply styling and formatting in the generated output document using the HTML bas

- Underline text.

- Set height and width of an image.

- Create [Hyperlinks](../document-generation-api/hyperlink.md).

- Create [Inline Images](../document-generation-api/inlineimages.md).
Expand Down Expand Up @@ -51,6 +53,12 @@ Styling for the text tag can be provided using the json data through the HTML ba

- Any HTML tags which are not supported will be ignored.

Formatting for image can be provided using the attributes of the img tag.

- The img tag supports the height and width attributes.

- Any other unsupported attributes inside the img tag will be ignored.

## Inline styling attributes supported

- font-size : Xpt or Ypx ; X=dynamic positive integer 1–1638 pt, 1pt = 1/72 inch; Y=dynamic positive integer 1–2184 px, 1px = 1/96 inch ( point (pt) and pixels (px) are the only supported unit for font size.)
Expand Down
17 changes: 17 additions & 0 deletions src/pages/overview/document-generation-api/templatetags.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,16 @@ A prefix value can be specified for the placeholder variable. Doing so will appe
this value before the result of the tag.

![Placeholder tags with prefix image set](../images/placeholder_prefix.png)

**Functions**

The Document Generation API supports a variety of functions that are compliant with JSONata.

<InlineAlert slots="text"/>

Please note that the `$match()` and `$split()` functions are *not* supported


## Images

To dynamically insert an image in the document, add any image as
Expand Down Expand Up @@ -384,6 +394,12 @@ Dynamically generate a numbered or bullet list by placing it inside a repeating

![Template tag items are replaced by numbered or bullet list](../images/simple_lists.png)

<InlineAlert slots="text"/>

The repeating section can only accept values that are present as keys in the JSON.



## Numerical Calculations

Performing numerical calculations on the input data.
Expand Down Expand Up @@ -456,3 +472,4 @@ These tags are converted into Adobe Sign form fields when the final document is
<InlineAlert slots="text"/>

Please visit [Adobe Sign Text Tag Guide](https://helpx.adobe.com/in/sign/using/text-tag.html) to learn about different Adobe Sign text tags.

Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,10 @@ Dynamically generate a numbered or bullet list by placing it inside a repeating

![Template tag items are replaced by numbered or bullet list](../images/simple_lists.png)

<InlineAlert slots="text"/>

Only JSON keys should be placed inside a repeating section.


## Conditionals

Expand Down
Binary file not shown.
72 changes: 69 additions & 3 deletions src/pages/resources/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"openapi": "3.0.1",
"info": {
"title": "PDF Services API",
"description": "<p><ul>\n\t<li>Learn more about using \n\t<a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/howtos/api-usage/\"> Adobe PDF Services API.</a>\n\t</li>\n\t<li> Invoking PDF Services API requires an Adobe-provided credential, <a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/gettingstarted/#step-1--getting-the-access-token\">learn more about authentication.</a>\n\t</li>\n<li><a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/#sdk\">Downloadable SDKs</a></li>\n<li><a href=\"https://raw.githubusercontent.com/AdobeDocs/pdfservices-api-documentation/main/src/pages/resources/Platform%20PDF%20Services%20Postman%20Collection.zip\" download>Click here</a> to download sample Postman collection</li>\n<li><a href=\"https://raw.githubusercontent.com/AdobeDocs/pdfservices-api-documentation/main/src/pages/resources/Platform%20PDF%20Services%20with%20External%20Storage%20Postman%20Collection.zip\">Click here</a> to download sample Postman collection with External Storage</li><li><a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/howtos/service-region-configuration-for-apis/\">Click here</a> to know more about <b>multi-region support</b> for PDF Services API</li><li><a href=\"https://community.adobe.com/t5/document-services-apis/ct-p/ct-Document-Cloud-SDK\">Support Forum</a></li><li>First released on 26th September, 2022</li><li>To use your custom external storage, click <a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/howtos/pdf-external-storage-sol\">here</a>.</li></ul></p>",
"description": "<p><ul>\n\t<li>Learn more about using \n\t<a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/howtos/api-usage/\"> Adobe PDF Services API.</a>\n\t</li>\n\t<li> Invoking PDF Services API requires an Adobe-provided credential, <a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/gettingstarted/#step-1--getting-the-access-token\">learn more about authentication.</a>\n\t</li>\n<li><a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/#sdk\">Downloadable SDKs</a></li>\n<li><a href=\"https://raw.githubusercontent.com/AdobeDocs/pdfservices-api-documentation/main/src/pages/resources/Platform%20PDF%20Services%20Postman%20Collection.zip\" download>Click here</a> to download sample Postman collection</li>\n<li><a href=\"https://raw.githubusercontent.com/AdobeDocs/pdfservices-api-documentation/new_features_and_postmancollection/src/pages/resources/Platform%20PDF%20Services%20with%20External%20Storage%20Postman%20Collection.zip\">Click here</a> to download sample Postman collection with External Storage</li><li><a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/howtos/service-region-configuration-for-apis/\">Click here</a> to know more about <b>multi-region support</b> for PDF Services API</li><li><a href=\"https://community.adobe.com/t5/document-services-apis/ct-p/ct-Document-Cloud-SDK\">Support Forum</a></li><li>First released on 26th September, 2022</li><li>To use your custom external storage, click <a href=\"https://developer.adobe.com/document-services/docs/overview/pdf-services-api/howtos/pdf-external-storage-sol\">here</a>.</li></ul></p>",
"version": ""
},
"servers": [
Expand Down Expand Up @@ -7420,7 +7420,14 @@
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/AccessibilityChecker"
"oneOf": [
{
"$ref": "#/components/schemas/AccessibilityCheckerInternal"
},
{
"$ref": "#/components/schemas/AccessibilityCheckerExternal"
}
]
}
}
},
Expand Down Expand Up @@ -11531,7 +11538,8 @@
},
"additionalProperties": false
},
"AccessibilityChecker": {
"AccessibilityCheckerInternal": {
"title": "Internal",
"description": "Parameter for PDF Accessibility Checker API operation.",
"type": "object",
"required": [
Expand Down Expand Up @@ -11573,6 +11581,64 @@
},
"additionalProperties": false
},
"AccessibilityCheckerExternal": {
"title": "External",
"description": "Parameter for PDF Accessibility Checker API operation.",
"type": "object",
"required": [
"input"
],
"properties": {
"input": {
"$ref": "#/components/schemas/ExternalStorageInput"
},
"output": {
"$ref": "#/components/schemas/ExternalStorageOutputZip"
},
"params": {
"description": "Params for Accessibility Checker processing",
"type": "object",
"properties": {
"pageStart": {
"description": "The parameter allows for the specification of the starting page for the accessibility check. If \"pageStart\" is not provided, the first page is considered the default startPage. It should be greater than equal to 1.",
"type": "number"
},
"pageEnd": {
"description": "The parameter allows for the specification of the ending page for the accessibility check. If \"pageEnd\" is not provided, the last page is considered the default pageEnd. It should be greater than equal to 1.",
"type": "number"
}
}
},
"notifiers": {
"$ref": "#/components/schemas/notifiers"
}
},
"example": {
"inputs": {
"document": {
"uri": "https://dcplatformstorageservice-dev-us-east-1.s3-accelerate.amazonaws.com/dc-platformService-automation_dc-platformService-automation%40AdobeID/1c4f4674-ce8d-4b21-a69d-60aeae35bf43?X-Amz-Security-Token=FwoGZXIvYXdzEBkaDK%2By2wxl94khIbkxzCLTAQn6n6Wo0vFSul%2FpXW66aFX4T%2BPxtuOy%2Bz8eTxrnexeJRvMreBHNQm1myLwp20MkE%2Bb0H%2BwYgOhFaepi9AMml1aLNxXn1UPnEWJ7y8llhvsrXHimEfWvb3TMAkZddgUIDBue8oGUYqm4f2s0sMvPWBCxI45zM0%2F37EK%2B4JnIo1SlrKNm0GSZ44AEiOAhXupQ8ih6KoUbUciD3Biile6CwTMVIhME3mJiRSgVK6W91EaDn8%2Ba3mU%2BVvU1K9sgDSPZ%2F81DOpj25pvMW%2B1cMuCtUNsu9KUo7dHvpAYyLYiy%2FPGEmO9EquKjfMPRr17PAjeunD1QdgbRss4ysG%2B6XF2Has8zsGqX1sQalA%3D%3D&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20230628T081557Z&X-Amz-SignedHeaders=host&X-Amz-Expires=3599&X-Amz-Credential=ASIAU5PA7W47IMX73XEA%2F20230628%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=ac6998566dbbde22509b128fe94d1cb5d3146cd3fb8ba78d7068e10d61302ec2",
"storage": "S3"
}
},
"params": {
"pageStart": 1,
"pageEnd": 5
},
"notifiers": [
{
"type": "CALLBACK",
"data": {
"url": "https://dummy.callback.org/",
"headers": {
"x-api-key": "dummykey",
"access-token": "dummytoken"
}
}
}
]
},
"additionalProperties": false
},
"AddWatermarkInternal": {
"title": "Internal",
"description": "Params for Watermark Operation",
Expand Down

0 comments on commit 88a02e5

Please sign in to comment.