Planfix API action.update: Difference between revisions

From Planfix
Jump to: navigation, search
No edit summary
No edit summary
Line 139: Line 139:


== Go To ==
== Go To ==
*[[Planfix API: Actions]]  
*[[Planfix API:Actions]]  
*[[Error codes]]
*[[Error codes]]
*[[List of functions]]
*[[List of functions]]

Revision as of 14:19, 4 August 2023

Function for updating data in an action. Request format:

<?xml version="1.0" encoding="UTF-8"?>
<request method="action.update">
  <account></account>
  <sid></sid>
  <action>
    <id></id>
    <description></description>
    <taskNewStatus></taskNewStatus>
    <notifiedList>
      <user>
        <id></id>
        <id></id>
        <!-- ... -->
      </user>
    </notifiedList>
    <isHidden></isHidden>
    <dateTime></dateTime>
    <analitics>
      <analitic>
        <id></id>
        <analiticData>
          <key></key>
          <itemData>
            <fieldId></fieldId>
            <value></value>
          </itemData>
          <itemData>
            <fieldId></fieldId>
            <value></value>
          </itemData>
          <!-- ... -->
        </analiticData>
      </analitic>
      <!-- ... -->
      <analitic>
        <id></id>
        <analiticData>
          <itemData>
            <fieldId></fieldId>
            <value></value>
          </itemData>
          <itemData>
            <fieldId></fieldId>
            <value></value>
          </itemData>
          <!-- ... -->
        </analiticData>
      </analitic>
      <!-- ... -->
    </analitics>
    <deletedAnalitics>
      <key></key>
      <key></key>
      <!-- ... -->
    </deletedAnalitics>
  </action>
  <signature></signature>
</request>
Name Type Value Notes
id int action identifier
description string text with action/comment description
taskNewStatus enum this action changes the task statuses to the one specified not required; for a list of valid values, see the task statuses section; attempting to change to an invalid status or to change the status of an action that isn't the most recent will result in an error
notifiedList the following list of users must be notified of this action
notifiedList.user list of users who will receive a notification
notifiedList.user.id int user identifier
isHidden bool whether or not the action (comment) is hidden from all users, excluding the list of those notified not required, by default set to 0 (false)
dateTime DateTime date/time of creation; not required; by default not changed can only be used if an employee with admin rights is logged in
datatags list of data tags updated not required
datatags.datatag node containing data from a data tag
datatag.id int data tag identifier for a list of available data tags, use the datatag.getList function
datatag.datatagData list of field values
datatagData.key int data tag row identifier; if this attribute is used, the data tag with this identifier will be used; if it is not used, a new data tag row will be added
datatagData.itemData value of one of the parameters
itemData.fieldId int parameter identifier identifier of the parameter equal to feild.id
itemData.value string value
deletedDatatags list of deleted data tags
deletedDatatags.key int key of deleted data tags this field is available after executing the function datatag.getData
signature string(32) signature


Remember, you can update ACTION and COMMENT actions. Attempts to update other types of actions will result in an error.

Result of successful request:

<?xml version="1.0" encoding="UTF-8"?>
<response status="ok">
  <action>
    <id></id>
  </action>
</response>
Name Type Value Notes
action.id int identifier of the modified action


Otherwise, an error response will be returned:

<?xml version="1.0" encoding="UTF-8"?>
<response status="error">
  <code></code>
</response>


Go To