API Dokumentation
+API Documentation
-
-
- 1. Einführung +
- 1. Intro
- 2.
- Interfaces
-
-
-
- 2.1 XML-RPC -
- 3. - Methoden + Methods
Einführung
+Intro
- Die Iro API enthält Funktion, die für den Massenversand nützlich sind. + Iro API has many methods, that are usefull if you want to send a bunch of messages. This Site describes the API for Iro 1.0.
Interfaces
- Die Iro API stellt zur Zeit nur ein Interfaces bereit. + You can use diffrent interfaces to get to same result.
XML-RPC
- Interface-URI: https://<benutzer>:<passwort>@localhost:8000
+ Interface-URI: http://localhost:8000/xmlrpc
+
SOAP
+
+ Interface-URI: http://localhost:8000/soap
+
JSON
+
+ Interface-URI: http://localhost:8000/json/<methode>
- Die aufgerufene Methode wird dabei im <methodName /> übergeben.
+ Not yet implementet
+
JSONP
+
+ Interface-URI: http://localhost:8000/jsonp/<methode>?callback=<callback>
+
+ Not yet implementet
Methoden
-StartSMS
-startSMS(message, recipients, provider='default')
Versendet eine SMS.
+Methods
+Status
+status(user=None, id=False, detailed=None)
Returns the status of one or more jobs.
Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description | +
| user | +string | +apikey of a user | +|||
| id | +integer | +one job id | +|||
| detailed | +boolean | +return more details about the status | +
Return
+| parameter | +type | +description | |||
| message | -string | -Nachricht | -|||
| recipients | -list | -eine Liste von Emfänger-Nummern (gemäß ITU-T E.123) | -|||
| provider | -string | -Provider über den geschickt werden soll | +return | +dict | +
|
Ausgabe
+Sms
+sms(user, message, recipients, route='default', info='')
Send a sms.
+Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| id | -hash | -Die ID des Auftrages | +user | +string | +apikey of a user | +
| message | +string | +message | +|||
| recipients | +list | +a list of telefon numbers (use ITU-T E.123) | +|||
| route | +string|list | +route to use to send, or a list of routes as fallback | +|||
| info | +string | +a name, to combine different jobs to one billing group |
StartFAX
-startFAX(subject, fax, recipients, provider='default')
Versendet ein FAX.
-Parameter
+Return
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| subject | -string | -der Betreff | -|||
| fax | -string | -das pdf base64 kodiert | -|||
| recipients | -list | -eine Liste von Emfänger-Nummern (gemäß ITU-T E.123) | -|||
| provider | -string | -Provider über den geschickt werden soll | +return | +integer | +the job id |
Ausgabe
+Fax
+fax(user, subject, fax, recipients, route='default', info='')
Send a fax.
+Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| id | -hash | -Die ID des Auftrages | +user | +string | +apikey of a user | +
| subject | +string | +subject | +|||
| fax | +string | +content (base64 encoded) | +|||
| recipients | +list | +a list of telefon numbers (use ITU-T E.123) | +|||
| route | +string|list | +route to use to send, or a list of routes as fallback | +|||
| info | +string | +a name, to combine different jobs to one billing group |
StartMail
-startMail(subject, body, recipients, frm, provider='default')
Versendet eine Email.
+Return
+| parameter | +type | +description | +
| return | +integer | +the job id | +
mail(user, subject, body, recipients, frm=None, route='default', info='')
Send a mail.
Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| user | +string | +apikey of a user | +|||
| subject | string | -der Betreff | +subject | ||
| body | string | -der Email Body | +mail body | ||
| recipients | list | -eine Liste von Emailadressen | +a list of email addresses | ||
| frm | string | -Die Absender Emailadresse | +sender mail address | ||
| provider | +route | +string|list | +route to use to send, or a list of routes as fallback | +||
| info | string | -Provider über den geschickt werden soll | +a name, to combine different jobs to one billing group |
Ausgabe
+Return
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| id | -hash | -Die ID des Auftrages | +return | +integer | +the job id |
Status
-status(id=None, detailed=False)
Gibt den aktuellen Status eines Auftrages zurück.
+Routes
+routes(user, typ=None)
Returns a list of all possible offernames.
Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| id | -hash | -Eine Auftragsnummer | +user | +string | +apikey of a user |
| detailed | -boolean | -Details ausgeben | +typ | +string | +a typ of message -- one of in this list ["sms","fax","mail"] |
Ausgabe
+Return
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description | +
| return | +list | +a list of all possible offer names for a typ | +
DefaultRoute
+defaultRoute(user, typ=None)
Returns all default offernames.
+Parameter
+| parameter | +type | +description | ||
| jobs | -list | -Eine Liste der Aufträge. | -||
| job.name | +user | string | -Angebener Name | +apikey of a user |
| job.status | +typ | string | -Status des Auftrages | +a typ of message -- one of in this list ["sms","fax","mail"] |
Stop
-stop(id)
Stoppt den angegeben Auftrag.
+Return
+| parameter | +type | +description | +
| return | +list | +a list of all possible offer names for a typ | +
Bill
+bill(user=None)
Returns the bill, of not paid messages.
Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| id | -hash | -Eine Auftragsnummer | +user | +string | +apikey of a user |
GetProvider
-getProvider(typ)
Gibt eine Liste aller verfügbaren Provider zurück.
-Parameter
+Return
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| typ | -string | -Der Typ zu dem die Providerloste ausgeben werden soll -Einer der Liste ["sms","fax","mail"] | +return | +dict | +
|
Ausgabe
+Telnumber
+telnumber(recipients)
Return True, if all telnumbers a vaild.
+Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| providerlist | +recipients | list | -Eine Liste aller möglichen Provider | +a list of telnumbers (use ITU-T E.123) |
GetDefaultProvider
-getDefaultProvider(typ)
Gibt den Standardprovider zurück.
-Parameter
+Return
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| typ | -string | -Der Typ zu dem die Providerloste ausgeben werden soll -Einer der Liste ["sms","fax","mail"] | +return | +boolean | +True -- all numbers are valid |
Ausgabe
+email(recipients)
Return True, if all mailadresses a valid.
+Parameter
| Parameter | -Typ | -Beschreibung | +parameter | +type | +description |
| provider | -string | -Der Standardprovider für den angeben Typ | +recipients | +list | +a list of mailadresses | +
Return
+| parameter | +type | +description | +
| return | +boolean | +True -- all addresses are valid |