Update a webhook status

Mit dieser Methode können Sie den Status eines Webhooks ändern.

PUT

/webhook/:id/status

Abfrage-Parameter

id
notwendig
Webhook ID

Body-Parameter

status
notwendig
Der Webhook-Status (live, paused)

Beispiele



PUT /webhook/66 HTTP/1.1
Host: api.smsup.ch
Authorization: Bearer your.token
Accept: application/json

{
  "webhook":{
    "status": "live"
  }
}
      
    

PUT /webhook/66 HTTP/1.1
Host: api.smsup.ch
Authorization: Bearer your.token
Accept: application/xml


<?xml version="1.0" encoding="UTF-8"?>
  <webhook>
    <status>live</status>
  </webhook>
    
  

Ergebnisformat



{
  "status": 1,
  "message": "OK",
  "webhook": {
        "webhook_id": "66",
        "status": "live",
        "type": "MO",
        "url": "https://mywebhook.com/mo",
        "signature": null
  }
}
          
        


<?xml version="1.0" encoding="UTF-8"?>
<response>
  <status>1</status>
  <message>OK</message>
  <webhook>
    <webhook_id>66</webhook_id>
    <status>live</status>
    <type>MO</type>
    <url>https://mywebhook.com/mo</url>
    <signature>null</signature>
  </webhook>
</response>