---
category: [Administration & Integrations, Platform and Product Extensions, Platform and Product Extensions/Integration, Administration & Integrations/Custom Integrations & Apps, Platform and Product Extensions/Workday Extend]
keyword: [Extend, Presentation Components, widgets, tags, UI components]
nav: wcp_docs
parent_url: /wcp_docs/
title: outboundData
layout: subsection
wd_wcptag: outboundData
---

<a id="section_N10021_N1001E_N10001"></a>
Contains the outbound endpoints and variables that persist data from the page widgets. Use `outboundData` only on edit pages.

<a id="section_N10098_N10088_N10001"></a>
The presence of `outboundData` in a PMD enables the page widgets for user input and automatically renders the <b>OK</b> and <b>Cancel</b> buttons at the bottom of the page. The PMD sends outbound data to the specified REST API endpoints or app variables.

<a id="section_xz1_wjc_ccb"></a>
Use `outboundData`:

-   To enable users to enter data on the page widgets.

    When the user clicks <b>OK</b> on the edit page, Presentation Components submit the outbound endpoints. The endpoint request bodies contain data from the outbound widget values.

-   If you need to pass variables across multiple PMDs within a flow.

    When the user clicks <b>OK</b> on the edit page, the page saves the outbound variables in the app variables based on their scope.



## <a id="section_a14_1dx_g2b"></a>Example

This sample outboundData contains an outbound endpoint that creates a requisition, and an outbound variable that saves the created requisition. The `requisition` endpoint uses the `onSend` event handler to format the request body.

```
  "outboundData": {
    "outboundEndPoints": [
      {
        "name": "requisition",
        "baseUrlType": "workday-procurement",
        "url": "requisitions",
        "authType": "sso",
        "httpMethod": "POST",
        "onSend": "<%
          self.data = {:};

          self.data.requester = {:};
          self.data.requester.id = instanceListWorker.getValue()[0];

          self.data.requisitionLines = [];
          var requisitionLine = {:};
          requisitionLine.item = {:};
          requisitionLine.item.id = site.appProperties.purchaseItem;
          requisitionLine.quantity = 1;
          requisitionLine.memo = string:join([name.getValue(), title.getValue(), address.getValue(), phone.getValue(), mobile.getValue(), email.getValue()], '|');
          self.data.requisitionLines.add(requisitionLine);

          self.data;
         %>"
      },
      {
        "type": "outboundVariable",
        "name": "requisitionVars",
        "variableScope": "flow",
        "values": [
          {
            "outboundPath": "createdRequisition",
            "value": "<% requisition %>"
          }
        ]
      }
    ],
    "responseErrorDetail": {
      "errorSummary": "<% error %>",
      "errors": "<% list:mapAttribute(errors, 'error') %>"
    }
  }
```

## <a id="section_mobileSupport"></a>Mobile Support

Android, iOS

## <a id="section_qpw_1kc_ccb"></a>Attributes

-   <b>outboundEndpoints</b>

    Data type: list of outboundEndPoint objects

    An array containing outbound endpoints and variables:

    -   [outboundDataURI](/wcp_docs/yzz1530025276777.html#) - (Default) Represents an outbound REST API endpoint used for persisting data input on the page.
    -   [outboundVariable](/wcp_docs/lmd1529983805787.html#) - Variable definitions passed across PMDs.

-   <b>responseErrorDetail</b>

    Data type: responseErrorDetail

    Specifies the error summary and detailed error data from the outbound endpoints. You can specify only 1 `responseErrorDetail` for all outbound endpoints in`outboundEndPoints[]`. An endpoint HTTP response code other than 2xx triggers the page to display the error messages.

    Example:

    ```
    "responseErrorDetail": {
    "errorSummary": "<% error %>",
    "errors": "<% errors.map(item => { item.error }); %>"
    }
    ```



### Related Information

[Concept: Submitting Data](/wcp_docs/rmd1572291186381.html)

[outboundEndPoints](/wcp_docs/kdd1594147277519.html)

[responseErrorDetail](/wcp_docs/lgo1595000847400.html)

[App Catalog: Order Business Cards](/app-catalog/businessCards)

