github.com/twilio/twilio-go@v1.20.1/rest/verify/v2/docs/ServicesWebhooksApi.md (about) 1 # ServicesWebhooksApi 2 3 All URIs are relative to *https://verify.twilio.com* 4 5 Method | HTTP request | Description 6 ------------- | ------------- | ------------- 7 [**CreateWebhook**](ServicesWebhooksApi.md#CreateWebhook) | **Post** /v2/Services/{ServiceSid}/Webhooks | 8 [**DeleteWebhook**](ServicesWebhooksApi.md#DeleteWebhook) | **Delete** /v2/Services/{ServiceSid}/Webhooks/{Sid} | 9 [**FetchWebhook**](ServicesWebhooksApi.md#FetchWebhook) | **Get** /v2/Services/{ServiceSid}/Webhooks/{Sid} | 10 [**ListWebhook**](ServicesWebhooksApi.md#ListWebhook) | **Get** /v2/Services/{ServiceSid}/Webhooks | 11 [**UpdateWebhook**](ServicesWebhooksApi.md#UpdateWebhook) | **Post** /v2/Services/{ServiceSid}/Webhooks/{Sid} | 12 13 14 15 ## CreateWebhook 16 17 > VerifyV2Webhook CreateWebhook(ctx, ServiceSidoptional) 18 19 20 21 Create a new Webhook for the Service 22 23 ### Path Parameters 24 25 26 Name | Type | Description 27 ------------- | ------------- | ------------- 28 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 29 **ServiceSid** | **string** | The unique SID identifier of the Service. 30 31 ### Other Parameters 32 33 Other parameters are passed through a pointer to a CreateWebhookParams struct 34 35 36 Name | Type | Description 37 ------------- | ------------- | ------------- 38 **FriendlyName** | **string** | The string that you assigned to describe the webhook. **This value should not contain PII.** 39 **EventTypes** | **[]string** | The array of events that this Webhook is subscribed to. Possible event types: `*, factor.deleted, factor.created, factor.verified, challenge.approved, challenge.denied` 40 **WebhookUrl** | **string** | The URL associated with this Webhook. 41 **Status** | **string** | 42 **Version** | **string** | 43 44 ### Return type 45 46 [**VerifyV2Webhook**](VerifyV2Webhook.md) 47 48 ### Authorization 49 50 [accountSid_authToken](../README.md#accountSid_authToken) 51 52 ### HTTP request headers 53 54 - **Content-Type**: application/x-www-form-urlencoded 55 - **Accept**: application/json 56 57 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 58 [[Back to Model list]](../README.md#documentation-for-models) 59 [[Back to README]](../README.md) 60 61 62 ## DeleteWebhook 63 64 > DeleteWebhook(ctx, ServiceSidSid) 65 66 67 68 Delete a specific Webhook. 69 70 ### Path Parameters 71 72 73 Name | Type | Description 74 ------------- | ------------- | ------------- 75 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 76 **ServiceSid** | **string** | The unique SID identifier of the Service. 77 **Sid** | **string** | The Twilio-provided string that uniquely identifies the Webhook resource to delete. 78 79 ### Other Parameters 80 81 Other parameters are passed through a pointer to a DeleteWebhookParams struct 82 83 84 Name | Type | Description 85 ------------- | ------------- | ------------- 86 87 ### Return type 88 89 (empty response body) 90 91 ### Authorization 92 93 [accountSid_authToken](../README.md#accountSid_authToken) 94 95 ### HTTP request headers 96 97 - **Content-Type**: Not defined 98 - **Accept**: Not defined 99 100 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 101 [[Back to Model list]](../README.md#documentation-for-models) 102 [[Back to README]](../README.md) 103 104 105 ## FetchWebhook 106 107 > VerifyV2Webhook FetchWebhook(ctx, ServiceSidSid) 108 109 110 111 Fetch a specific Webhook. 112 113 ### Path Parameters 114 115 116 Name | Type | Description 117 ------------- | ------------- | ------------- 118 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 119 **ServiceSid** | **string** | The unique SID identifier of the Service. 120 **Sid** | **string** | The Twilio-provided string that uniquely identifies the Webhook resource to fetch. 121 122 ### Other Parameters 123 124 Other parameters are passed through a pointer to a FetchWebhookParams struct 125 126 127 Name | Type | Description 128 ------------- | ------------- | ------------- 129 130 ### Return type 131 132 [**VerifyV2Webhook**](VerifyV2Webhook.md) 133 134 ### Authorization 135 136 [accountSid_authToken](../README.md#accountSid_authToken) 137 138 ### HTTP request headers 139 140 - **Content-Type**: Not defined 141 - **Accept**: application/json 142 143 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 144 [[Back to Model list]](../README.md#documentation-for-models) 145 [[Back to README]](../README.md) 146 147 148 ## ListWebhook 149 150 > []VerifyV2Webhook ListWebhook(ctx, ServiceSidoptional) 151 152 153 154 Retrieve a list of all Webhooks for a Service. 155 156 ### Path Parameters 157 158 159 Name | Type | Description 160 ------------- | ------------- | ------------- 161 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 162 **ServiceSid** | **string** | The unique SID identifier of the Service. 163 164 ### Other Parameters 165 166 Other parameters are passed through a pointer to a ListWebhookParams struct 167 168 169 Name | Type | Description 170 ------------- | ------------- | ------------- 171 **PageSize** | **int** | How many resources to return in each list page. The default is 50, and the maximum is 1000. 172 **Limit** | **int** | Max number of records to return. 173 174 ### Return type 175 176 [**[]VerifyV2Webhook**](VerifyV2Webhook.md) 177 178 ### Authorization 179 180 [accountSid_authToken](../README.md#accountSid_authToken) 181 182 ### HTTP request headers 183 184 - **Content-Type**: Not defined 185 - **Accept**: application/json 186 187 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 188 [[Back to Model list]](../README.md#documentation-for-models) 189 [[Back to README]](../README.md) 190 191 192 ## UpdateWebhook 193 194 > VerifyV2Webhook UpdateWebhook(ctx, ServiceSidSidoptional) 195 196 197 198 199 200 ### Path Parameters 201 202 203 Name | Type | Description 204 ------------- | ------------- | ------------- 205 **ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc. 206 **ServiceSid** | **string** | The unique SID identifier of the Service. 207 **Sid** | **string** | The Twilio-provided string that uniquely identifies the Webhook resource to update. 208 209 ### Other Parameters 210 211 Other parameters are passed through a pointer to a UpdateWebhookParams struct 212 213 214 Name | Type | Description 215 ------------- | ------------- | ------------- 216 **FriendlyName** | **string** | The string that you assigned to describe the webhook. **This value should not contain PII.** 217 **EventTypes** | **[]string** | The array of events that this Webhook is subscribed to. Possible event types: `*, factor.deleted, factor.created, factor.verified, challenge.approved, challenge.denied` 218 **WebhookUrl** | **string** | The URL associated with this Webhook. 219 **Status** | **string** | 220 **Version** | **string** | 221 222 ### Return type 223 224 [**VerifyV2Webhook**](VerifyV2Webhook.md) 225 226 ### Authorization 227 228 [accountSid_authToken](../README.md#accountSid_authToken) 229 230 ### HTTP request headers 231 232 - **Content-Type**: application/x-www-form-urlencoded 233 - **Accept**: application/json 234 235 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) 236 [[Back to Model list]](../README.md#documentation-for-models) 237 [[Back to README]](../README.md) 238