Definition

PUT - 3/surveys/{surveyId}/pages/{pageNumber}/branching

Early access feature - Updates page branch logic.

Required roles: Survey (write)

Request information

surveyId

The id of a survey.


Type integer
Additional info
Required
pageNumber

The id of a survey.


Type integer
Additional info
Required

Logic object to create page branching.

Logics

Collection of logic items


Type Collection of LogicUpdate
ElsePage

Logic details of the Else branch


Type ElsePage
Sample:
{
  "Logics": [
    {
      "LogicOperatorId": 1,
      "Items": [
        {
          "MetadataTypeId": 64,
          "OperatorId": 2,
          "QuestionId": 1,
          "ResponseId": 1,
          "Value": "sample string 3",
          "QueryStringParameter": "sample string 4",
          "LogicItemId": 1,
          "IsDeleted": true
        },
        {
          "MetadataTypeId": 64,
          "OperatorId": 2,
          "QuestionId": 1,
          "ResponseId": 1,
          "Value": "sample string 3",
          "QueryStringParameter": "sample string 4",
          "LogicItemId": 1,
          "IsDeleted": true
        }
      ],
      "GotoPage": 1,
      "GotoURL": {
        "RespondentStatus": 1,
        "Url": "sample string 1"
      },
      "LogicId": 2
    },
    {
      "LogicOperatorId": 1,
      "Items": [
        {
          "MetadataTypeId": 64,
          "OperatorId": 2,
          "QuestionId": 1,
          "ResponseId": 1,
          "Value": "sample string 3",
          "QueryStringParameter": "sample string 4",
          "LogicItemId": 1,
          "IsDeleted": true
        },
        {
          "MetadataTypeId": 64,
          "OperatorId": 2,
          "QuestionId": 1,
          "ResponseId": 1,
          "Value": "sample string 3",
          "QueryStringParameter": "sample string 4",
          "LogicItemId": 1,
          "IsDeleted": true
        }
      ],
      "GotoPage": 1,
      "GotoURL": {
        "RespondentStatus": 1,
        "Url": "sample string 1"
      },
      "LogicId": 2
    }
  ],
  "ElsePage": {
    "ElsePageLogicId": 1,
    "ElseGotoPage": 2,
    "ElseGotoURL": {
      "RespondentStatus": 1,
      "Url": "sample string 1"
    }
  }
}
Sample:
<LogicsUpdate xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <Logics>
    <LogicUpdate>
      <LogicOperatorId>AND</LogicOperatorId>
      <Items>
        <LogicItemUpdate>
          <MetadataTypeId>64</MetadataTypeId>
          <OperatorId>2</OperatorId>
          <QuestionId>1</QuestionId>
          <ResponseId>1</ResponseId>
          <Value>sample string 3</Value>
          <QueryStringParameter>sample string 4</QueryStringParameter>
          <LogicItemId>1</LogicItemId>
          <IsDeleted>true</IsDeleted>
        </LogicItemUpdate>
        <LogicItemUpdate>
          <MetadataTypeId>64</MetadataTypeId>
          <OperatorId>2</OperatorId>
          <QuestionId>1</QuestionId>
          <ResponseId>1</ResponseId>
          <Value>sample string 3</Value>
          <QueryStringParameter>sample string 4</QueryStringParameter>
          <LogicItemId>1</LogicItemId>
          <IsDeleted>true</IsDeleted>
        </LogicItemUpdate>
      </Items>
      <GotoPage>1</GotoPage>
      <GotoURL>
        <RespondentStatus>ReachedEnd</RespondentStatus>
        <Url>sample string 1</Url>
      </GotoURL>
      <LogicId>2</LogicId>
    </LogicUpdate>
    <LogicUpdate>
      <LogicOperatorId>AND</LogicOperatorId>
      <Items>
        <LogicItemUpdate>
          <MetadataTypeId>64</MetadataTypeId>
          <OperatorId>2</OperatorId>
          <QuestionId>1</QuestionId>
          <ResponseId>1</ResponseId>
          <Value>sample string 3</Value>
          <QueryStringParameter>sample string 4</QueryStringParameter>
          <LogicItemId>1</LogicItemId>
          <IsDeleted>true</IsDeleted>
        </LogicItemUpdate>
        <LogicItemUpdate>
          <MetadataTypeId>64</MetadataTypeId>
          <OperatorId>2</OperatorId>
          <QuestionId>1</QuestionId>
          <ResponseId>1</ResponseId>
          <Value>sample string 3</Value>
          <QueryStringParameter>sample string 4</QueryStringParameter>
          <LogicItemId>1</LogicItemId>
          <IsDeleted>true</IsDeleted>
        </LogicItemUpdate>
      </Items>
      <GotoPage>1</GotoPage>
      <GotoURL>
        <RespondentStatus>ReachedEnd</RespondentStatus>
        <Url>sample string 1</Url>
      </GotoURL>
      <LogicId>2</LogicId>
    </LogicUpdate>
  </Logics>
  <ElsePage xmlns:d2p1="http://schemas.datacontract.org/2004/07/CheckMarket.Common.APIModels">
    <d2p1:ElseGotoPage>2</d2p1:ElseGotoPage>
    <d2p1:ElseGotoURL>
      <RespondentStatus>ReachedEnd</RespondentStatus>
      <Url>sample string 1</Url>
    </d2p1:ElseGotoURL>
    <d2p1:ElsePageLogicId>1</d2p1:ElsePageLogicId>
  </ElsePage>
</LogicsUpdate>

Response information

Returns status message if the launch was successful or not.


Meta

The metadata such as paging parameters, status code, timestamp,... which are related to this request.


Type MetaData
Data

The actual data returned by the request.


Links

HATEOAS related to this object. It wil contain relevant url's such as previous and next page for paged results, create/update/delete action. These url's can be used in your application for the next steps in your application logic.


Type Hateoas
Sample:
{
  "Meta": {
    "Status": 1,
    "TotalRowCount": 1,
    "Limit": 1,
    "Offset": 1,
    "TotalPageCount": 1,
    "StartRec": 1,
    "StopRec": 1,
    "Timestamp": "2024-12-22T05:23:19.7231154Z",
    "IsFiltered": true
  },
  "Data": {
    "Succeeded": true,
    "FailureMessage": "sample string 2"
  }
}
Sample:
<Payload xmlns:i="http://www.w3.org/2001/XMLSchema-instance" z:Id="i1" xmlns:z="http://schemas.microsoft.com/2003/10/Serialization/">
  <Data>
    <FailureMessage>sample string 2</FailureMessage>
    <Succeeded>true</Succeeded>
  </Data>
  <Meta>
    <IsFiltered>true</IsFiltered>
    <Limit>1</Limit>
    <Offset>1</Offset>
    <StartRec>1</StartRec>
    <Status>1</Status>
    <StopRec>1</StopRec>
    <Timestamp>2024-12-22T05:23:19.7231154+00:00</Timestamp>
    <TotalPageCount>1</TotalPageCount>
    <TotalRowCount>1</TotalRowCount>
  </Meta>
</Payload>