Skip to main content
PUT
/
api
/
v2
/
public
/
application
/
event
/
:event_id
Update event
curl --request PUT \
  --url https://api.gocobalt.io/api/v2/public/application/event/:event_id \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "name": "<string>",
  "response": {}
}
'
[
    {
        "_id": "64c8d0e22f6f5ad7ce6b4a62",
        "name": "Add Contact",
        "response": [
            {
                "key": "first_name",
                "type": "text"
            },
            {
                "key": "last_name",
                "type": "text"
            },
            {
                "key": "email",
                "type": "text"
            },
            {
                "key": "phone",
                "type": "text"
            },
            {
                "key": "id",
                "type": "text"
            },
            {
                "key": "prospect",
                "type": "object"
            },
            {
                "key": "prospect.first_name",
                "type": "text"
            },
            {
                "key": "prospect.email",
                "type": "text"
            }
        ],
        "raw_response": "{\"first_name\":\"John\",\"last_name\":\"Doe\",\"email\":\"john.doe@example.com\",\"phone\":\"1234567890\",\"id\":\"9876543\",\"prospect\":{\"first_name\":\"John\",\"email\":\"john.doe@example.com\"}}"
    },
    {
        "_id": "64c8d0f92f6f5ad7ce6b4a6a",
        "name": "Delete Contact",
        "response": [
            {
                "key": "contact_id",
                "type": "text"
            },
            {
                "key": "app_contact_id",
                "type": "text"
            }
        ],
        "raw_response": "{\"contact_id\":\"64e4742936ee94ac84be2d35\",\"app_contact_id\":\"\"}"
    }
]
This API updates a Refold event of your org’s app.

Request description

Path Parameters

event_id
string
required
Event Id. For Eg: 64c8d0e22f6f5ad7ce6b4a62

Body Parameters

name
string
required
Updated Event Name
response
object
required
Updated event model. This model’s properties are accessed in the workflow as trigger variables.
Example payload
  {
    "event": "event name",
    "payload": {
      "jobid": "677677AE59",
      "firstname": "nanami",
      "lastname": "jjk",
      "email": "nana@jjk.com",
      "headline": "Professional sorcerer"
    }
  }

Response description

Returns an array of all events in the org after the update.
_id
string
Event Id
name
string
Name of the event
response
array
Array of response field objects derived from the event model
raw_response
string
Raw JSON string of the event payload
[
    {
        "_id": "64c8d0e22f6f5ad7ce6b4a62",
        "name": "Add Contact",
        "response": [
            {
                "key": "first_name",
                "type": "text"
            },
            {
                "key": "last_name",
                "type": "text"
            },
            {
                "key": "email",
                "type": "text"
            },
            {
                "key": "phone",
                "type": "text"
            },
            {
                "key": "id",
                "type": "text"
            },
            {
                "key": "prospect",
                "type": "object"
            },
            {
                "key": "prospect.first_name",
                "type": "text"
            },
            {
                "key": "prospect.email",
                "type": "text"
            }
        ],
        "raw_response": "{\"first_name\":\"John\",\"last_name\":\"Doe\",\"email\":\"john.doe@example.com\",\"phone\":\"1234567890\",\"id\":\"9876543\",\"prospect\":{\"first_name\":\"John\",\"email\":\"john.doe@example.com\"}}"
    },
    {
        "_id": "64c8d0f92f6f5ad7ce6b4a6a",
        "name": "Delete Contact",
        "response": [
            {
                "key": "contact_id",
                "type": "text"
            },
            {
                "key": "app_contact_id",
                "type": "text"
            }
        ],
        "raw_response": "{\"contact_id\":\"64e4742936ee94ac84be2d35\",\"app_contact_id\":\"\"}"
    }
]