messaging v1 short name.html - swisscom-api/doc GitHub Wiki

SMS added value services

Overview

Swisscom is required by law to inform subscribers of its mobile services about providers of SMS added services. This API complements the web resources that Swisscom publishes online.

API Resources

GET /messaging/v1/shortname/shortids/{shortId}

Get provider details for a given short ID

Request
Headers
  • client_id (Id to authenticate client)
  • Accept (application/json)
  • shortId (Short ID for which you want to obtain provider information; part of URI)
Response

Example:

https://api.swisscom.com/messaging/v1/shortname/shortids/50051

{
   "id":1270,
   "shortID":"50051",
   "systemtype":"sms",
   "shortidstate":"blocked",
   "hotlinephone":"0800800800",
   "hotlineemail":"[email protected]",
   "hotlinetime":"Mo - Fr 08:00 - 17:00h\nSa\nSo",
   "providername":"Mondia Media Group GmbH",
   "provideraddress1":"Kehrwieder 8",
   "provideraddress2":null,
   "providerzip":"20457",
   "providercity":"Hamburg",
   "descriptionDE":"Für weitere Informationen bitte nur via email [email protected]",
   "descriptionFR":"Pour plus des info, veuillez envoyer une email à  [email protected]",
   "descriptionIT":"Per oltre informazioni vi preghiamo di mandare una email : [email protected]",
   "descriptionEN":"Please send your request only by using the emailadr. [email protected]"
}
Error Responses

400, 401, 403, 404, 405, 406, 429, 500, 503

GET /messaging/v1/shortname/providers/{providerName}

Get all short numbers of a given provider.

Request
Headers
  • client_id (Id to authenticate client)
  • Accept (application/json)
  • providerName (Name of the service provider to search on. Use '%' as wildcard character and be sure to url-encode it (%37); part of URI)
Response

Example:

https://api.swisscom.com/messaging/v1/shortname/providers/Mondia%20Media%37

[
   {
      "name": "Mondia Media Group GmbH",
      "address1": "Kehrwieder 8",
      "address2": null,
      "zip": "20457",
      "city": "Hamburg",
      "shortids": 
      [
         "50051"
      ]
   },
   {
      "name": "Mondia Media Group GmbH",
      "address1": null,
      "address2": null,
      "zip": "",
      "city": null,
      "shortids": 
      [
         "SG",
         "SGR01"
      ]
   }
]
Error Responses

400, 401, 403, 404, 405, 406, 429, 500, 503