Folgende SOAP-Methoden werden speziell für die Interaktion mit Gutscheincodelisten bereitgestellt.
generate
User anhand des Usernamens finden
EvalancheUser generate(int coupon_list_id, int amount)
Details
Parameter
- int coupon_list_id: ID der Gutscheincodeliste
- int amount: Anzahl der zu generierenden Gutscheincodes
Rückgabewert
- generateResult: Boolean: Ergebnis
Benötigte Rechte
Gutscheincodeliste verwaltenVerwendung
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:coup="https://scnem.com/soap.php/soap/couponlist">
<soapenv:Header/>
<soapenv:Body>
<coup:generate>
<coupon_list_id>COUPON_LIST_ID</coupon_list_id>
<amount>AMOUNT</amount>
</coup:generate>
</soapenv:Body>
</soapenv:Envelope>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="https://scnem.com/soap.php/soap/couponlist">
<SOAP-ENV:Body>
<ns1:generateResponse>
<generateResult>true/false</generateResult>
</ns1:generateResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
getProfileCouponList
Liste aller Gutscheincodes auslesen
EvalancheUser[] getProfileCouponList(int coupon_list_id)
Details
Parameter
- int coupon_list_id: ID der Gutscheincodeliste
Rückgabewert
- CouponList[]:
- int id: Coupon ID
- string code: Couponcode
- int profile_id: Profile ID
- int creation_date: Erstellungsdatum
- int valid_to: Code Ablaufdatum
Benötigte Rechte
Gutscheincodeliste verwaltenVerwendung
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:coup="https://scnem.com/soap.php/soap/couponlist">
<soapenv:Header/>
<soapenv:Body>
<coup:getProfileCouponList>
<coupon_list_id>COUPON_LIST_ID</coupon_list_id>
</coup:getProfileCouponList>
</soapenv:Body>
</soapenv:Envelope>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="https://scnem.com/soap.php/soap/couponlist">
<SOAP-ENV:Body>
<ns1:getProfileCouponListResponse>
<getProfileCouponListResult>
<item>
<id>COUPON_ID</id>
<code>CODE</code>
<profile_id>PROFILE_ID</profile_id>
<creation_date>CREATION_DATE</creation_date>
<valid_to>VALID_TO</valid_to>
</item>
[...]
</getProfileCouponListResult>
</ns1:getProfileCouponListResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
import
Importiert bestehende Gutscheincodes in eine bestehende Gutscheincodeliste
EvalancheUser import(EvalancheUser user)
Details
Parameter
- CouponList:
- int id: Gutscheincodeliste ID
- string code: Gutscheincode
- int profile_id: optionale Profil ID
- int creation_date: Erstelldatum des Gutscheins
- int valid_to: Ablaufdatum des Gutscheins
Rückgabewert
- importResult: boolean
Benötigte Rechte
Gutscheincodeliste verwaltenVerwendung
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:coup="https://scnem.com/soap.php/soap/couponlist">
<soapenv:Header/>
<soapenv:Body>
<coup:import>
<coupon_list_id>USER_ID</coupon_list_id>
<data>
<item>
<id>CODE_ID</id>
<code>COUPON_CODE</code>
<profile_id>PROFILE_ID</profile_id>
<creation_date>CREATION_DATE</creation_date>
<valid_to>VALID_TO</valid_to>
</item>
<!--Zero or more repetitions:-->
</data>
</coup:import>
</soapenv:Body>
</soapenv:Envelope>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="https://scnem.com/soap.php/soap/couponlist">
<SOAP-ENV:Body>
<ns1:importResponse>
<importResult>true/false</importResult>
</ns1:importResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>