Menu

Rate this page:

Thanks for rating this page!

We are always striving to improve our documentation quality, and your feedback is valuable to us. How could this documentation serve you better?

Sync REST: Sync Services

A Service is the top-level scope of all other resources in the REST API. It is fundamentally a container for the objects in a Sync application. Services allow you to:

  • Create multiple environments (dev, stage, prod) under the same Twilio account with segregated data
  • Scope access to resources through the REST API
  • Configure behavior of those resources in the scope of a Service

Example

{
  "links": {
    "maps": "https://sync.twilio.com/v1/Services/ISxx/Maps",
    "documents": "https://sync.twilio.com/v1/Services/ISxx/Documents",
    "lists": "https://sync.twilio.com/v1/Services/ISxx/Lists"
  },
  "date_updated": "2022-06-08T10:24:53Z",
  "friendly_name": "sample_sync_instance",
  "account_sid": "ACxx",
  "url": "https://sync.twilio.com/v1/Services/ISxx",
  "reachability_webhooks_enabled": false,
  "sid": "ISxx",
  "date_created": "2022-06-08T10:21:13Z",
  "webhook_url": "http://example.com/",
  "acl_enabled": "true"
}

Actions


List All Services

GET /v1/Services
Loading Code Sample...
      
      
          
          
          
          
        

      Create a Service

      POST /v1/Services
      

      Parameters

      AclEnabled
      Optional
      post boolean Not PII

      true or false - determines whether token identities must be granted access to Sync objects via the Permissions API in this Service.

      FriendlyName
      Optional
      post string Not PII

      Human-readable name for this service instance

      ReachabilityWebhooksEnabled
      Optional
      post boolean Not PII

      true or false - controls whether this instance fires webhooks when client endpoints connect to Sync Defaults to false.

      WebhookUrl
      Optional
      post url Not PII

      A URL that will receive event updates when objects are manipulated.

      Loading Code Sample...
          
          
              
              
              
              
            
          Loading Code Sample...
              
              
                  
                  
                  
                  
                

              Retrieve a Service

              GET /v1/Services/ISxx
              

              Example

              Loading Code Sample...
                  
                  
                      
                      
                      
                      
                    

                  Update a Service

                  POST /v1/Services/ISxx
                  

                  Parameters

                  AclEnabled
                  Optional
                  post boolean Not PII

                  true or false - determines whether token identities must be granted access to Sync objects via the Permissions API in this Service.

                  FriendlyName
                  Optional
                  post string Not PII

                  Human-readable name for this service instance

                  ReachabilityWebhooksEnabled
                  Optional
                  post boolean Not PII

                  True or false - controls whether this instance fires webhooks when client endpoints connect to Sync Defaults to false.

                  WebhookUrl
                  Optional
                  post url Not PII

                  A URL that will receive event updates when objects are manipulated.

                  Loading Code Sample...
                      
                      
                          
                          
                          
                          
                        

                      Delete A Service

                      DELETE /v1/Services/ISxx
                      

                      Example

                      Loading Code Sample...
                          
                          
                              
                              
                              
                              
                            

                          Need some help?

                          We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd browsing the Twilio tag on Stack Overflow.

                          Loading Code Sample...