github.com/twilio/twilio-go@v1.20.1/rest/serverless/v1/docs/ServicesApi.md (about) 1 # ServicesApi 2 3 All URIs are relative to *https://serverless.twilio.com* 4 5 Method | HTTP request | Description 6 ------------- | ------------- | ------------- 7 [**CreateService**](ServicesApi.md#CreateService) | **Post** /v1/Services | 8 [**DeleteService**](ServicesApi.md#DeleteService) | **Delete** /v1/Services/{Sid} | 9 [**FetchService**](ServicesApi.md#FetchService) | **Get** /v1/Services/{Sid} | 10 [**ListService**](ServicesApi.md#ListService) | **Get** /v1/Services | 11 [**UpdateService**](ServicesApi.md#UpdateService) | **Post** /v1/Services/{Sid} | 12 13 14 15 ## CreateService 16 17 > ServerlessV1Service CreateService(ctx, optional) 18 19 20 21 Create a new Service resource. 22 23 ### Path Parameters 24 25 This endpoint does not need any path parameter. 26 27 ### Other Parameters 28 29 Other parameters are passed through a pointer to a CreateServiceParams struct 30 31 32 Name | Type | Description 33 ------------- | ------------- | ------------- 34 **UniqueName** | **string** | A user-defined string that uniquely identifies the Service resource. It can be used as an alternative to the `sid` in the URL path to address the Service resource. This value must be 50 characters or less in length and be unique. 35 **FriendlyName** | **string** | A descriptive string that you create to describe the Service resource. It can be a maximum of 255 characters. 36 **IncludeCredentials** | **bool** | Whether to inject Account credentials into a function invocation context. The default value is `true`. 37 **UiEditable** | **bool** | Whether the Service's properties and subresources can be edited via the UI. The default value is `false`. 38 39 ### Return type 40 41 [**ServerlessV1Service**](ServerlessV1Service.md) 42 43 ### Authorization 44 45 [accountSid_authToken](../README.md#accountSid_authToken) 46 47 ### HTTP request headers 48 49 - **Content-Type**: application/x-www-form-urlencoded 50 - **Accept**: application/json 51 52 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 53 [[Back to Model list]](../README.md#documentation-for-models) 54 [[Back to README]](../README.md) 55 56 57 ## DeleteService 58 59 > DeleteService(ctx, Sid) 60 61 62 63 Delete a Service resource. 64 65 ### Path Parameters 66 67 68 Name | Type | Description 69 ------------- | ------------- | ------------- 70 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 71 **Sid** | **string** | The `sid` or `unique_name` of the Service resource to delete. 72 73 ### Other Parameters 74 75 Other parameters are passed through a pointer to a DeleteServiceParams struct 76 77 78 Name | Type | Description 79 ------------- | ------------- | ------------- 80 81 ### Return type 82 83 (empty response body) 84 85 ### Authorization 86 87 [accountSid_authToken](../README.md#accountSid_authToken) 88 89 ### HTTP request headers 90 91 - **Content-Type**: Not defined 92 - **Accept**: Not defined 93 94 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 95 [[Back to Model list]](../README.md#documentation-for-models) 96 [[Back to README]](../README.md) 97 98 99 ## FetchService 100 101 > ServerlessV1Service FetchService(ctx, Sid) 102 103 104 105 Retrieve a specific Service resource. 106 107 ### Path Parameters 108 109 110 Name | Type | Description 111 ------------- | ------------- | ------------- 112 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 113 **Sid** | **string** | The `sid` or `unique_name` of the Service resource to fetch. 114 115 ### Other Parameters 116 117 Other parameters are passed through a pointer to a FetchServiceParams struct 118 119 120 Name | Type | Description 121 ------------- | ------------- | ------------- 122 123 ### Return type 124 125 [**ServerlessV1Service**](ServerlessV1Service.md) 126 127 ### Authorization 128 129 [accountSid_authToken](../README.md#accountSid_authToken) 130 131 ### HTTP request headers 132 133 - **Content-Type**: Not defined 134 - **Accept**: application/json 135 136 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 137 [[Back to Model list]](../README.md#documentation-for-models) 138 [[Back to README]](../README.md) 139 140 141 ## ListService 142 143 > []ServerlessV1Service ListService(ctx, optional) 144 145 146 147 Retrieve a list of all Services. 148 149 ### Path Parameters 150 151 This endpoint does not need any path parameter. 152 153 ### Other Parameters 154 155 Other parameters are passed through a pointer to a ListServiceParams struct 156 157 158 Name | Type | Description 159 ------------- | ------------- | ------------- 160 **PageSize** | **int** | How many resources to return in each list page. The default is 50, and the maximum is 1000. 161 **Limit** | **int** | Max number of records to return. 162 163 ### Return type 164 165 [**[]ServerlessV1Service**](ServerlessV1Service.md) 166 167 ### Authorization 168 169 [accountSid_authToken](../README.md#accountSid_authToken) 170 171 ### HTTP request headers 172 173 - **Content-Type**: Not defined 174 - **Accept**: application/json 175 176 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 177 [[Back to Model list]](../README.md#documentation-for-models) 178 [[Back to README]](../README.md) 179 180 181 ## UpdateService 182 183 > ServerlessV1Service UpdateService(ctx, Sidoptional) 184 185 186 187 Update a specific Service resource. 188 189 ### Path Parameters 190 191 192 Name | Type | Description 193 ------------- | ------------- | ------------- 194 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 195 **Sid** | **string** | The `sid` or `unique_name` of the Service resource to update. 196 197 ### Other Parameters 198 199 Other parameters are passed through a pointer to a UpdateServiceParams struct 200 201 202 Name | Type | Description 203 ------------- | ------------- | ------------- 204 **IncludeCredentials** | **bool** | Whether to inject Account credentials into a function invocation context. 205 **FriendlyName** | **string** | A descriptive string that you create to describe the Service resource. It can be a maximum of 255 characters. 206 **UiEditable** | **bool** | Whether the Service resource's properties and subresources can be edited via the UI. The default value is `false`. 207 208 ### Return type 209 210 [**ServerlessV1Service**](ServerlessV1Service.md) 211 212 ### Authorization 213 214 [accountSid_authToken](../README.md#accountSid_authToken) 215 216 ### HTTP request headers 217 218 - **Content-Type**: application/x-www-form-urlencoded 219 - **Accept**: application/json 220 221 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 222 [[Back to Model list]](../README.md#documentation-for-models) 223 [[Back to README]](../README.md) 224