Connect a Service

Connect a social media service to a contract to be able to collect content from it.

Endpoint

GET https://api.crowdynews.com/social-connect/connect/{service}

Request Parameters

URL PARAMETER VALUE DESCRIPTION
service The name of the social media provider to connect to. Must be one of:
  • twitter
  • instagram
  • facebook
  • tumblr
QUERY PARAMETER VALUE DESCRIPTION
access_token A valid OAuth access token with the correct permission(s).
contract_id The resource ID that specifies to which contract the social media provider will be connected. The consumer that wants to connect must have access to the specified contract, otherwise this action is forbidden.
origin_uri Optional. A URI that denotes the origin that initiated the connect request. When the flow completes, the API will redirect to this URI. When this parameter is used, the URI will expose additional parameters: status or error and service. For example, on success the URL will read ?status=ok&service=twitter and on failure ?error=This account is already activated&service=instagram.

Response Format

On success, the HTTP status code in the response header is 200 OK. On error, the header status code is an error code and the response body contains an error object.

Note that when the origin_uri request parameter is omitted, a self closing HTML page will be served out on success and an error page on failure.

Example Request

Request:

GET https://api.crowdynews.com/social-connect/connect/twitter?contract_id=565c4df4056e859526e62257&access_token={your access token}

Response:

HTTP/1.1 200

Additional Resources