WebHooks

Version 6



    What is it?

    V3 API for registering for asynchronous POSTs to your service about content activity from a place.

     

    What are the common use cases?

    Performing the following without polling:

    • Bidirectional commenting
    • Synchronizing content between systems

     

    How do I use it?

    • Acquire the placeURI for the place you wish to listen content events for.
    • Acquire an access token for a user who has access to the place.
    • POST a request to the Jive instance specifying the placeURI as the source of content activity, with optional filters for events, and the URL of your service.

      curl --header 'Authorization: Bearer <access token here>' --header 'Content-Type: application/json;charset=UTF-8' -X POST  -d '{"callback":"http://<service callback URL here>","object":"http://<jive URL here>:8080/api/core/v3/place/<placeID here>"}' "http://<jive URL here>/api/core/v3/webhooks"

       

        If successful, you should get a 200 OK response from Jive, and JSON describing your newly created webhook.

    {
        "id": "1006",
        "resources": {
              "self": {
                    "allowed": [ "GET", "PUT", "DELETE" ],
                    "ref": "http://<jive URL here>/api/core/v3/webhooks/1006"  
              }
        },
        "object": "http://<jive URL here>/api/core/v3/places/<place ID here>",
        "callback": "http://<service callback URL here>"
    }
    
    
    
    
    
    

       

    • When Jive encounters activity within that place, your service endpoint will be POSTed with a signed header and activity payload in V3 API activity format. For example:
    {
      "content": "Aron created<ahref="http://lt-a7-120000.jiveland.com:8080/external/3174">tileStreamEntry</a>in<ahref="http://lt-a7-120000.jiveland.com:8080/groups/fadf">fadf</a>",
      "title": "Activity1380078589019",
      "jive": {
          "productIcon": "http: //lt-a7-120000.jiveland.com: 8080/api/core/v3/images/5078",
          "iconCss": "jive-icon-medjive-icon-tile-activityexternal-object-1249",
          "replyCount": 0,
          "objectID": 3174,
          "collectionUpdated": "2013-09-25T03: 09: 49.064+0000",
          "collection": "-960826044-3174",
          "productName": "WebhooksTileExample",
          "objectType": -960826044,
          "onBehalfOf": [ Object ]
        },
      "verb": "jive: created",
      "updated": "2013-09-25T03: 09: 49.064+0000",
      "target": {
          "id": "http: //lt-a7-120000.jiveland.com: 8080/api/core/v3/places/8995",
          "summary": "",
          "updated": "2013-09-25T03: 08: 49.071+0000",
          "image": [ Object ],
          "displayName": "fadf",
          "published": "2013-09-24T15: 59: 06.124+0000",
          "objectType": "jive: group",
          "url": "http: //lt-a7-120000.jiveland.com: 8080/groups/fadf"
        },
      "provider": {
          "displayName": "Jive",
          "objectType": "jive: instance",
          "url": "http: //lt-a7-120000.jiveland.com: 8080"
        },
      "object": {
          "id": "http: //lt-a7-120000.jiveland.com: 8080/api/core/v3/contents/9485",
          "summary": "Activity1380078589019",
          "updated": "2013-09-25T03: 09: 49.039+0000",
          "displayName": "Activity1380078589019",
          "published": "2013-09-25T03: 09: 49.039+0000",
          "objectType": "jive: extStreamActivity",
          "url": "http: //lt-a7-120000.jiveland.com: 8080/external/3174"
        },
      "published": "2013-09-25T03: 09: 49.064+0000",
      "url": "http: //lt-a7-120000.jiveland.com: 8080/external/3174"
    }
    
    
    
    
    
    

     

    References & Further Reading