Capability Exposure Platform API Dokümanı 2.16 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 1 / 107
Yasal Uyarı / Telif Hakları Tüm hakları saklıdır. İşbu döküman ve dökümanın her türlü içerik ve malzemesi (yazılı ve görsel) ve yayın hakkı Vodafone Teknoloji Hizmetleri A.Ş. nin mülkiyetindedir ; bu içerik, malzeme ve dökümanlara ilişkin telif hakkı ve/veya diğer fikri mülkiyet hakları ilgili mavzuat ve kanunlarca korunmakta olup; döküman kısmen veya tamamen hiçbir surette izin alınmadan ve kaynak gösterilmeden kullanılamaz, değiştirilemez, kopyalanamaz, çoğaltılamaz, yeniden yayımlanamaz, iletilemez ya da dağıtılamaz. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 2 / 107
İçindekiler 1. Giriş... 6 1.1. Amaç... 6 1.2. Tanımlar, kısaltmalar ve baş harf kısaltmaları... 6 2. API Kullanımı Genel Bilgiler... 7 2.1. Kimlik Doğrulama (Authentication)... 7 2.1.1. REST Arayüzü... 8 2.1.2. SOAP Arayüzü... 9 2.1.3. İşlem belirteci (Transaction Id)... 10 2.1.4. Servis Seans Belirteci (Service Session Id)... 10 2.2. İstek belirteci (requestid) kullanımı... 11 2.3. Akış belirteci (usageid) kullanımı... 11 2.4. CapexSubscriberId ve RestCapexSubscriberId... 11 2.5. Abone belirteci ve opak belirteç kullanımı... 12 2.6. Yumuşak Geçiş (Soft Launch)... 14 2.7. Kullanım sınırlaması... 14 2.8. API kullanım kayıtları... 15 2.9. Sonuç Kodları... 15 2.9.1. REST Sonuç Kodları... 15 2.9.1.1. Servis Hatası (Service Exception)... 15 2.9.1.2. Politika Hatası (Policy Exception)... 15 2.9.2. SOAP Sonuç Kodları... 16 2.10. Mesajlaşma Api'lerinin kullanımı... 24 2.10.1. Poll Interface... 24 2.10.2. Push Interface... 25 2.10.3. SenderAddress... 25 2.10.4. SenderName... 25 2.10.5. RegistrationId... 25 2.10.6. Mesaj iletim raporu değerleri... 26 2.10.7. Mesaj iletim sonucu... 26 2.10.8. Saat Bazlı Mesaj Atımı Engellenmesi... 26 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 3 / 107
2.11. Rest wadl ve Soap wsdl... 27 2.12. WSDL'den kod oluşturulması... 27 3. Abone Profili API metodları... 28 3.1. Faturalı Abone... 29 3.1.1. REST arayüzü... 29 3.1.2. SOAP arayüzü... 30 3.2. Ön Ödemeli Abone... 31 3.2.1. REST Arayüzü... 32 3.2.2. SOAP Arayüzü... 33 3.3. Abone Aktiflik Durumu... 34 3.3.1. REST arayüzü... 34 3.3.2. SOAP arayüzü... 35 3.4. Abone Tüzel Kişiliği... 36 3.4.1. REST Arayüzü... 37 3.4.2. SOAP Arayüzü... 38 3.5. Abone Yaşı... 39 3.5.1. REST Arayüzü... 39 3.5.2. SOAP Arayüzü... 40 3.6. Abone Cinsiyeti... 41 3.6.1. REST Arayüzü... 42 3.6.2. SOAP Arayüzü... 43 3.7. Tarife Durumu... 44 3.7.1. REST Arayüzü... 44 3.7.2. SOAP Arayüzü... 45 3.8. Abone Segment Durumu... 46 3.8.1. REST Arayüzü... 47 3.8.2. SOAP Arayüzü... 48 3.9. FreeZone Durumu... 49 3.9.1. REST Arayüzü... 49 3.9.2. SOAP Arayüzü... 50 3.10. Doğum Günü Sorgulama... 52 3.10.1. REST Arayüzü... 52 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 4 / 107
3.10.2. SOAP Arayüzü... 54 4. SMS API Metodları... 56 4.1. SMS Gönderimi (OneAPI yöntemi)... 57 4.1.1. REST Arayüzü... 59 4.1.2. SOAP Arayüzü... 60 4.2. İletim Raporları Alımı... 62 4.2.1. REST Arayüzü... 63 4.2.2. SOAP Arayüzü... 64 4.3. SMS Mesajını Alma... 65 4.3.1. REST Arayüzü... 66 4.3.2. SOAP Arayüzü... 67 5. Konum ve Coğrafi Bilgi API Metodları... 70 5.1. Konum Sorgusu... 70 5.1.1. REST Arayüzü... 72 5.1.2. SOAP Arayüzü... 74 5.2. Grup Konum Sorgusu... 76 5.2.1. REST Arayüzü... 77 5.2.2. SOAP Arayüzü... 77 5.3. Konum Onayının Durum Bilgisini Sorgulama... 80 5.3.1. REST Arayüzü... 81 5.3.2. SOAP Arayüzü... 82 5.4. Adres Sorgusu... 83 5.4.1. SOAP Arayüzü... 84 5.4.2. REST Arayüzü... 85 5.5. İlgi Noktası (POI) sorgulama... 86 5.5.1. SOAP Arayüzü... 87 5.5.2. REST Arayüzü... 89 5.6. Rota Sorgulama... 91 5.6.1. SOAP Arayüzü... 92 5.6.2. REST Arayüzü... 94 6. Ek A POI Kategori Listesi... 96 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 5 / 107
1. Giriş 1.1. Amaç Bu dokümanın amacı Capability Exposure Platform (CEP) ile entegre olacak, servisler yazacak uygulama geliştiricilere rehber olmaktır. 1.2. Tanımlar, kısaltmalar ve baş harf kısaltmaları Term ACR CapEx CEP Definition (Anonymous Customer Reference) Anonim müşteri referansı Opak kimlik belirteci Opaque Id (Capability Exposure) Yetenek açığa çıkarma (Capability Exposure Platform) Yetenek Açığa Çıkarma Platformu. Dokümanda CEP ve MDPEx isimleri dönüşümlü olarak karşınıza çıkabilir. Yeni platformun adı CEP olarak geçecektir. MDP (Message Delivery Platform) Mesaj Teslim Platformu (MDP, dokümanın 2.16 versiyonu itibariyle kaldırılmıştır.) MDPEx REST SOAP (MDP Extended) Mesaj Teslim Platformu + CapEx uygulama programlama arayüzleri genişletmesini içeren geliştirilmiş mesaj teslim platformunun eski adı. Dokümanda CEP ve MDPEx isimleri dönüşümlü olarak karşınıza çıkabilir. Yeni platformun adı CEP olarak geçecektir. (MDPEx, dokümanın 2.16 versiyonu itibariyle kaldırılmıştır.) REpresentational State Transfer Simple Object Access Protocol Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 6 / 107
2. API Kullanımı Genel Bilgiler Vodafone CEP, iş ortaklarımızın ve girişimcilerin, Vodafone Telekomünikasyon Ağının yeteneklerinden de faydalanarak yaratıcı fikirlerini yenilikçi uygulamalar olarak Vodafone müşterilerinin hizmetine sunmalarını sağlamayı amaçlamaktadır. Bu amaçla endüstri standardı olmuş uygulama programlama arayüzleri temel alınarak zenginleştirilmiş ve uygulama geliştiricilerin Vodafone Hizmet Ağının sağladığı yeteneklerine kolayca entegre olabilmeleri hedeflenmiştir. CEP, Vodafone iş ortaklarının eskiden entegre oldukları MDP platformunun üzerine inşa edilmiş olup eski platformun yeteneklerinin hepsini barındırmaktadır. CEP, eski MDP sisteminin sağladığı müşterilerin bilgilendirilmesi, servis aboneliklerinin ve bunların ücretlendirmelerinin yönetimi, tekil içerik satışlarının yönetimi, entegre müşteri hizmetleri uygulaması gibi özellikleri sağlamasının yanı sıra mesajlaşma, abone profili bilgileri sorgulama, konum ve coğrafi bilgi sorgulama, ücretlendirme ve ücretlendirme onayı, aboneye ücretsiz dakika ve SMS yükleme gibi yeni özellikleri de sağlar. Bu yeteneklerle geliştirilecek servis çeşitliliğini artırmayı ve iş ortaklarımızla birlikte abonelerimize daha kaliteli servisler sunmayı amaçlıyoruz. Bu dokümanda açıklanan API metotlarının kullanımı için, Vodafone iş ortağı olmanız gerekmektedir. İş ortağı olmakla ilgili yasal prosedürlerinin tamamlanmasının ardından CEP Test Sistemine erişim yetkisi tanımlanması gerekmektedir. Bu erişim yetkisi uygulama sunucularınızın CEP Test Sistemi IP adreslerine erişebilmesi için gereken IP tanımlamalarıyla başlar. Ardından Servis Yönetimi Kullanıcı Arabirimi için kullanıcı adı ve şifre tanımlanmalıdır. Size sağlanacak kullanıcı adı ve şifre yardımıyla Servis Yönetimi Kullanıcı Arabirimine giriş yapıp bir servis tanımı yapmanız gerekmektedir. Bu servis tanımı aynı zamanda hangi API metotlarının kullanılacağına dair yetkilendirmeleri de içerecektir. Servis tanımının onaylanmasının ardından uygulamanızı platform üzerinden test etmeye başlayabilirsiniz. 2.1. Kimlik Doğrulama (Authentication) CEP API lerini kullanabilmek için önceden servis yönetim grafik arabiriminden yeni bir servis yaratmalı ve kullanıcı adı, şifre ve servis belirteci (service id) bilgilerini elde etmelisiniz. Bu bilgileri CEP sistemine yapacaginiz her istekte request içinde vermelisiniz. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 7 / 107
2.1.1. REST Arayüzü REST metodlarinda HTTP Basic Authentication kullanılmaktadır. REST isteklerinde http header'da username / password ve service id bilgisi gitmelidir. username@companyid:password string'i base64 ile encode edilmelidir. Encode edilen değer istekte http header da verilmelidir. Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ== şeklinde encode edilmiş bilgi verilmelidir. Bunun yanında serviceid header'ı ile de service id geçirilmelidir. Örnek istek şu şekildedir: POST http://localhost:8000/1/ussdmessaging/outbound/2655/subscriptions HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/x-www-form-urlencoded Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumtizna== serviceid: :2001000001 User-Agent: Jakarta Commons-HttpClient/3.1 Host: localhost:8000 Content-Length: 0 Yetkilendirme bilgileri eksik gelirse görülecek hata aşağıdaki gibidir. Bu durumda service id parametresi gönderilmemiş olabilir, ya da bilgiler yanlıştır. HTTP/1.1 400 Bad Request Content-Type: application/json Content-Length: 164 Server: Jetty(6.1.25) {"policyexception":null,"serviceexception":{"messageid":"svc0001","text":"a service error occurred. Error code is %1","variables":"52:Missing authorization info."}} Yetkilendirme bilgileri yanlış gelirse görülecek hata aşağıdadır. Bu durumda username / password / serviceid bilgisi yanlış olabilir ya da verilen servisin API metodunu kullanma yetkisi olmayabilir. HTTP/1.1 401 Unauthorized WWW-Authenticate: Basic realm=sdf Content-Type: text/html; charset=iso-8859-1 Cache-Control: must-revalidate,no-cache,no-store Content-Length: 1414 Server: Jetty(6.1.25) Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 8 / 107
<html> <head> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1"/> <title>error 401 Unauthorized</title> </head> <body> <h2>http ERROR 401</h2> <p>problem accessing /1/ussdmessaging/outbound/2655/subscriptions. Reason: <pre>unauthorized</pre> </p> <hr/> <i> <small>powered by Jetty://</small> </i> <br/> <br/> </body> </html> 2.1.2. SOAP Arayüzü SOAP metodlarinda USERNAMEPASSWORD ya da SESSIONID yetkilendirme tipleri kullanılabilir. SESSIONID kullanımı için, header'da sessionid isimli bir header doldurulmalı, usernamepassword kullanımı için ise password doldurulmalı. SOAP metodlarında ise yetkilendirme bilgisi SOAP header da bulunmalıdır. Aşağıda iki şekilde örnek verilmiştir. Örnek 1: <soapenv:header> <pms:authentication pms:user="capexuser@capexcmp" pms:password="123456" pms:serviceid=":2001000001"/> </soapenv:header> Örnek 2: <soapenv:header> <Authentication:usernamePassword Authentication:user="capexuser@capexcmp" Authentication:password="123456" Authentication:serviceid=":2001000001" xmlns:authentication="authentication"/> </soapenv:header> SessionBased authentication'da tokenid/sessionid almak için : <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:aut="http://authentication.services.system.sdf.oksijen.com"> <soapenv:header> <aut:authentication aut:user="sultan@1000000062" aut:password="sultan1234" aut:sessionid="" aut:serviceid=":2001000001"/> </soapenv:header> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 9 / 107
<soapenv:body> <aut:authenticate/> </soapenv:body> </soapenv:envelope> Cevap olarak sessionid gelecektir: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:authenticateresponse xmlns:ns="http://authentication.services.system.sdf.oksijen.com"> <return> <sessionid>ocjlrro1osdl6kgm0zpneyshm086ztun</sessionid> </return> </ns:authenticateresponse> </soapenv:body> </soapenv:envelope> 2.1.3. İşlem belirteci (Transaction Id) Servis kurgusuna göre, yapılan bir request ile asenkron olarak alınan cevabı eşleştirmek için kullanılan, zorunlu olmayan (optional) bir parametredir. CEP e yapılan bir istekte header'da verilebilir. 2.1.4. Servis Seans Belirteci (Service Session Id) Servis kurgusuna göre, yapilan birkaç request aynı session (aynı servis akışı) ile alakalı olabilir. Örnegin bir sms atılmasının ardından bu sms ile ilgili ücretlendirme isteği yapılıyorsa, bu aradaki ilişkiyi belirtmek için iki istekte de header'da servicesessionid değeri aynı verilerek eşleştirme yapılabilir. Özet olarak http header'da gönderilmesi gereken parametreler aşağıdaki tabloda verilmiştir. Parametre Adı Zorunlu Açıklama Authorization E username@companyid:password bilgisinin base64 encode edilmiş hali geçirilir serviceid E servis id transactionid H Herhangi bir istek asenkron bir cevap ile eşleştirilmek isteniyorsa kullanılabilir Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 10 / 107
servicesessionid H Birden fazla istek ve response bir service akışı ile eşleştirilmek isteniyorsa kullanılabilir 2.2. İstek belirteci (requestid) kullanımı OneApi metodlarında kullanılan istek belirteci requestid (type:string) parametresinin kullanımı sadece ilgili operasyon a özeldir. Örnek olarak sendsms operasyonu sonucu dönen requestid parametresi, ilgili mesajın iletim raporunu sorgulamak için kullanılacaktır. 2.3. Akış belirteci (usageid) kullanımı Abonenin ilk talebinin sisteme ulaşmasından, abonenin talebinin karşılanıp içeriğin sağlanmasına (tekil içerikler için) ya da aboneliğin yaratılıp o aboneliğin hayat döngüsü ve iptaline kadar gerçekleşen bütün işlemler aynı içerik belirteci usageid (type:long) ile gerçekleşir. usageid degerinin takip edilmesi ve ilişkisinin tutulması 3rd party servisinin sorumluluğundadır. OneApi kullanımında akışları birbirine bağlamak için usageid kullanılır. Devamında bu akış ile ilişkili olan tüm çağrılarda bu usageid bilgisi beklenmektedir, aksi takdirde bu akışın yeni bir akış olduğu farz edilerek sistem tarafından yeni bir usageid üretilecektir. 2.4. CapexSubscriberId ve RestCapexSubscriberId Parametre Veri Tipi Zorunlu Size Açıklama enduserid String E 20 byte Abonenin EndUserid sidir. usageid Long H Bağlanmak istenen akışa ait usageid bilgisidir. Verilmemesi durumunda yeni akış kabul edildiği için yeni bir usageid üretilip cevapta dönülür. nickname String H Abonenin nickname ini ifade eder. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 11 / 107
2.5. Abone belirteci ve opak belirteç kullanımı Uygulama ile CEP sistemi arasındaki bütün istek ve yanıtlarda Vodafone abonesinin id bilgisi 3 şekilde geçebilir:tc Kimlik No,MSISDN, Opak kimlik belirteci. (ACR) CEP sistemine doğru yapılan isteklerde servisin yetki durumununa göre bu üç id'den biri kullanılır. Dökümanın geri kalanında aboneyi tanımlayan bu belirteç değerine enduserid denecektir. Belirteç Formatı Sorgulama tipi tck:tcknumarası tel:+msisdn acr:opaqueid TCK numarası ile sorgulama International formatta telefon numarası ile sorgulama OpaqueId ile sorgulama TCK numarası kullanarak sorgu yaparsanız bu numaraya kayıtlı bir telefon numarası olup olmadığı kontrol edilir ve kayıtlı telefon numarası üzerinden işlem yapılır. OpaqueId(ACR) kullanımı lokasyon tabanlı servislerde zorunludur. Bir servis te lokasyon APIsi kullanılıyorsa, o servisteki bütün api çağrıları opaqueid üzerinden yapılmalıdır. OpqueId(ACR) ile yapılmış request örneği aşağıdadır. Burada address=acr%3a23423423423423423423423 değişkeni URL encoded olarak verilmiş opaqueid'li bir değerdir. POST http://localhost:8000/1/ussdmessaging/outbound/2655/requests/ HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/x-www-form-urlencoded Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumtizna== serviceid: :2001000001 User-Agent: Jakarta Commons-HttpClient/3.1 Host: localhost:8000 Content-Length: 50 message=test&address=acr%3a23423423423423423423423 Aynı istek msisdn kullanılarak yapılırsa: POST http://localhost:8000/1/ussdmessaging/outbound/2655/requests/ HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/x-www-form-urlencoded Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 12 / 107
Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumtizna== serviceid: :2001000001 User-Agent: Jakarta Commons-HttpClient/3.1 Host: localhost:8000 Content-Length: 42 message=test&address=tel%3a%2b90542xxxxxxx Aynı istek tck numarası kullanılarak yapılırsa: POST http://localhost:8000/1/ussdmessaging/outbound/2655/requests/ HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/x-www-form-urlencoded Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumtizna== serviceid: :2001000001 User-Agent: Jakarta Commons-HttpClient/3.1 Host: localhost:8000 Content-Length: 38 message=test&address=tck%3a31294419329 Msisdn kullanılarak yapılmış örnek bir lokasyon isteği: GET http://localhost:8000/1/location/queries/location?address=tel%3a%2b90543xxxxxxx HTTP/1.1 Accept-Encoding: gzip,deflate Accept: application/json User-Agent: Jakarta Commons-HttpClient/3.1 Host: localhost:8000 Eğer servisinize tanımlanmış ve yetki verilmiş Id formatından farklı bir formatla istekte bulunusanız aşagıdaki hata görülür: HTTP/1.1 500 Internal Server Error Content-Type: application/json Content-Length: 159 Server: Jetty(6.1.25) Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 13 / 107
{"policyexception":{"messageid":"pol0001","text":"a policy error occurred. Error code is %1","variables":"50:Wrong type of EndUserId"},"serviceException":null} Eğer geçersiz bir id ile istekte bulunulursa aşağıdaki hata dönülür: HTTP/1.1 400 Bad Request Content-Type: application/json Content-Length: 158 Server: Jetty(6.1.25) {"policyexception":null,"serviceexception":{"messageid":"svc0001","text":"a service error occurred. Error code is %1","variables":"1:EndUserId format error"}} 2.6. Yumuşak Geçiş (Soft Launch) CEP bir test platformu olarak kullanılabilir. Test aşamasındaki servislerde her istek için doğru cevap dönmemektedir. Servis yaratırken tanımladığınız telefon numarası ile test yaparsanız gerçek bilgileri alabilirsiniz. Fakat başka numaralar ile denerseniz gerçek değerlere benzer rastgele üretilmiş değerler alacaksınız. Bu şekilde istediğiniz numaralar ile değişik durumları test edebilirsiniz. Eğer kendi numaranız dışında bir numara ile de test yapmak isterseniz Vodafone ile temasa geçerek bu msisdn'leri test numaraları olarak kayıt ettirebilirsiniz. 2.7. Kullanım sınırlaması Abone profili API metodları için metod başına günlük ve aylık kullanım limitleri bulunmaktadır. Bu limitleri aştığınızda sistemden aşağıdaki limit hatasını alacaksınız. HTTP/1.1 500 Internal Server Error Content-Type: application/json Content-Length: 156 Server: Jetty(6.1.25) {"policyexception":{"messageid":"pol0001","text":"a policy error occurred. Error code is %1","variables":"25:Request limit error."},"serviceexception":null} Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 14 / 107
2.8. API kullanım kayıtları Yaptığınız bütün api çağrıları gelen/giden parametreleri ile birlikte loglanmaktadır. Bu loglara daha sonra HistoryApi üzerinden ulaşarak hangi apileri ne kadar kullandığınızı, hangi hataları aldığınızı görebilirsiniz. 2.9. Sonuç Kodları 2.9.1. REST Sonuç Kodları 2.9.1.1. Servis Hatası (Service Exception) Gönderilen isteğin formatı hatalıysa, parametreler geçerli değilse ya da eksikse bu tip hata dönülür. Servis hatası örneği şu şekildedir: HTTP/1.1 400 Bad Request Content-Type: application/json Content-Length: 158 Server: Jetty(6.1.25) {"policyexception":null,"serviceexception":{"messageid":"svc0001","text":"a service error occurred. Error code is %1","variables":"1:EndUserId format error"}} 2.9.1.2. Politika Hatası (Policy Exception) Gönderilen isteğin formatı doğruysa, fakat işleyişte bir hata oluşmuşsa bu tip hata dönülür. REST politika hatası örneği şu şekildedir: HTTP/1.1 500 Internal Server Error Content-Type: application/json Content-Length: 156 Server: Jetty(6.1.25) {"policyexception":{"messageid":"pol0001","text":"a policy error occurred. Error code is %1","variables":"25:Request limit error."},"serviceexception":null} Hata durumlarında değişkenler içerisinde gelen sayısal kod ve açıklama hata ile ilgili ayrintili bilgi vermektedir. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 15 / 107
Bütün hata kodlarının listesi aşağıdaki tablodadır. Genel olarak sistemden aşağıdaki exceptionlar alınabilir: Hata Kodu Açıklama Hata içeriği Değişken SVC0001 Genel Service exception A service error occurred. Error code is %1 POL0001 Genel Policy Exception A policy error occurred. Error code is %1 POL3001 MESSAGING_DUPLICATE_URL Duplicate subscription. Subscription exists with id %1 Genel hata kodlarından biri Genel hata kodlarından biri Varolan subscription id'si POL3002 MESSAGING_MAX_ADDRESS_LIST_SIZE_ERR OR Too many addresses. Max allowed %1 Max izin verilen address sayısı POL3003 SUBSC_OPS_SUBSCRIPTION_ALREADY_EXIST S Subscription already exists with id %1 Varolan aboneliğin id si POL0004 AOC_CONSENT_EXISTS Consent exists with id %1 Varolan consent_id POL3005 TOTAL_CHARGE_LIMIT_IS_REACHED Total charge limit is reached, left amount is %1 TL POL3006 SUBSCRIPTION_DOES_NOT_EXIST Related content subscription does not exist.related content id is %1 Toplam geriye kalmış olan miktar İlişkili içeriğin içerik numarası Detaylı bilgi için: https://gsma.securespsite.com/access/access%20api%20wiki/common%20policy%20exceptio ns.aspx https://gsma.securespsite.com/access/access%20api%20wiki/common%20service%20excepti ons.aspx 2.9.2. SOAP Sonuç Kodları Result code ve description olarak response içinde gelir. Aşağıdaki tablodan bakılabilir. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 16 / 107
Kod Açıklama Hata tipi 0 Success ServiceException 1 EndUserId format error PolicyException 10 Invalid channel PolicyException 11 Invalid reference code PolicyException 13 Invalid currency PolicyException 15 Invalid charge amount PolicyException 16 Invalid Date PolicyException 21 Reference code exists ServiceException 22 Transaction not found ServiceException 23 General system error! ServiceException 25 Request limit error. ServiceException 26 Invalid parameter error PolicyException 27 Invalid gender PolicyException 28 Invalid package id PolicyException 29 Invalid customer type PolicyException 30 Invalid segment PolicyException 31 Invalid option id PolicyException 32 Invalid campaign id PolicyException 33 User & Password error ServiceException 34 Invalid token id PolicyException 35 Missing Data PolicyException 36 Longtitude should not be empty! PolicyException 37 Invalid longtitude! PolicyException Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 17 / 107
38 Latitude should not be empty! PolicyException 39 Invalid latitude! PolicyException 40 route_preference should be FASTEST or SHORTEST! PolicyException 41 road_preference should be HIGHWAY or LOCAL! PolicyException 42 distance_unit should be KM, MILE or METER! PolicyException 43 time_unit should be HOUR, MINUTE or SECOND! PolicyException 44 return_driving_directions should be TRUE or FALSE! PolicyException 45 return_route_geometry should be TRUE or FALSE PolicyException 46 Please specify a valid category list! PolicyException 47 Poi count is 0! ServiceException 48 city should not be empty! PolicyException 50 Wrong type of EndUserId ServiceException 51 OpaqueId error ServiceException 52 Missing authorization info. PolicyException 53 Service is deleted. ServiceException 54 Service is passive. ServiceException 55 Address list cannot be empty. PolicyException 56 Request timeout! ServiceException 57 There is no such POI whithin the given limits! ServiceException 58 Route not found! ServiceException 59 History not found. ServiceException 60 Receivers list cannot be empty. PolicyException 61 Message cannot be empty. PolicyException 63 SenderAddress cannot be empty. PolicyException Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 18 / 107
64 Correlator exists. ServiceException 69 Invalid url. PolicyException 70 Cannot push msg. ServiceException 71 MMS parameter syntax invalid PolicyException 72 Sender name invalid. PolicyException 73 No record found. ServiceException 74 SenderName cannot be empty. PolicyException 75 Invalid msisdn. PolicyException 76 Invalid content. PolicyException 79 Subscription not found. ServiceException 80 SenderAddress is invalid. PolicyException 81 Only JSON Format is supported. PolicyException 82 Too many addresses. ServiceException 84 Destination address is invalid PolicyException 85 Subscription id is invalid PolicyException 86 Invalid description. PolicyException 87 Invalid code. PolicyException 88 WapPush Url should not be empty. PolicyException 89 AoC message content is invalid. PolicyException 90 Registration id is invalid. PolicyException 91 Operation not supported for this subscriber ServiceException 94 Max debit reached ServiceException 95 Invalid server reference code PolicyException 96 Invalid charge transaction status PolicyException Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 19 / 107
97 Invalid client correlator PolicyException 98 Client correlator exists ServiceException 99 Code not found ServiceException 100 Invalid Priority PolicyException 101 Already refunded ServiceException 102 Invalid message category PolicyException 103 Max URL size exceeded. PolicyException 104 Max Callbackdata size exceeded. PolicyException 105 Max message content size exceeded PolicyException 106 Max subject size exceeded PolicyException 107 MmaId not found ServiceException 108 Invalid voucher PolicyException 109 Invalid gift type PolicyException 110 Invalid content idcode PolicyException 111 Invalid Notify Url PolicyException 112 Invalid asset namedescription PolicyException 113 Invalid channel PolicyException 114 Invalid subscription id PolicyException 115 Operation not supported for this subscriber PolicyException 116 Request id is invalid. PolicyException 117 Content not supported. PolicyException 118 General system error! ServiceException 119 General system error! ServiceException 120 General system error! ServiceException Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 20 / 107
121 General system error! ServiceException 122 General system error! ServiceException 123 General system error! ServiceException 124 General system error! ServiceException 125 General system error! ServiceException 126 General system error! ServiceException 127 General system error! ServiceException 128 General system error! ServiceException 129 General system error! ServiceException 130 Invalid transaction id PolicyException 131 Promotion System Error ServiceException 130 Invalid subscriber ServiceException 131 Not supported ServiceException 132 Duplicate transaction id ServiceException 133 Invalid campaign id ServiceException 134 Load error ServiceException 135 Voucher is user ServiceException 136 Balance account not found ServiceException 137 Invalid date ServiceException 138 Subs not enough credit PolicyException 139 Subs charge error PolicyException 140 Address could not be found PolicyException 141 Operation not supported for this subscriber PolicyException 142 A-B scenario is not supported. PolicyException Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 21 / 107
143 Positioning not allowed PolicyException 144 Invalid aocid PolicyException 145 No aoc is taken PolicyException 146 Aoc expired PolicyException 147 Invalid amount for dynamic charging ServiceException 148 Not enough credit ServiceException 149 Max debit reached ServiceException 150 Subscriber charge failed ServiceException 151 Company charge failed ServiceException 153 Operation not supported for this subscriber ServiceException 154 Content state is invalid ServiceException 155 EndUserId is in blacklist ServiceException 156 Refund for wrong EndUserId ServiceException 157 Refund not allowed for reference code ServiceException 158 Invalid mms attachment data PolicyException 159 Invalid mms subject PolicyException 160 Invalid mms content name PolicyException 161 Invalid mms content type PolicyException 162 Aoc id not found PolicyException 163 Aoc id msisdn mismatch PolicyException 164 Operation not supported for corporate subscribers. ServiceException 165 Refund for amount is not supported PolicyException 166 Requester cannot be null or empty. ServiceException 167 Invalid event type PolicyException Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 22 / 107
168 Requester address cannot be empty if there is a nickname. ServiceException 169 Operation not supported for the subscriber in message text. PolicyException 170 OpaqueId error for the subscriber in message text. PolicyException 171 Waiting For Location Consent ServiceException 172 NickName should not be null or empty,it should be alphanumeric. ServiceException 173 Your service card type is category. Requester should be null ServiceException 174 Requester address cannot be empty if there is a usageid. ServiceException 175 Requested address cannot be empty if there is a usageid. ServiceException 176 Requested address cannot be empty if there is a nickname. ServiceException 177 Location consent is rejected. ServiceException 178 Cannot send message in blackhour. ServiceException 179 Subscriber cannot locate himself. ServiceException 180 Operation not supported for the subscriber in key. PolicyException 181 OpaqueId error for the subscriber in key. PolicyException 182 Softlaunch; subscriber in text is not test msisdn. PolicyException 183 Invalid subscription key PolicyException 184 Invalid requester. PolicyException 185 Content is not active ServiceException 186 General system error! ServiceException 187 Multiple MT limit is reached. ServiceException 188 Invalid content id. ServiceException 192 Content's aoc type is invalid. ServiceException 193 RequestId not found. ServiceException 194 Amount should be within dynamic price plan range. ServiceException Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 23 / 107
195 Not enough total amount left. Cancelling consent and subscription. ServiceException 196 Difference between startdate and enddate must be greater. ServiceException 197 Invalid date parameter. ServiceException Ücretlendirme ile ilgili hata kodları şu şekildedir: Açıklama Kod UNKNOWN 0 NOT_ENOUGH_CREDIT 4010 NOT_ENOUGH_CREDIT_CONTINUE 4020 FAILED 4030 SKIPPED 4040 MAX_DEBIT_REACHED 4050 2.10. Mesajlaşma Api'lerinin kullanımı SMS ve MMS mesajlaşma api'lerinde abone tarafından atılan mesajlar ve iletim raporları uygulamaya kısa numara ve mesaj içeriğine göre dağıtılır. Mesaj gönderme API'sine (sendsms, sendwappush, sendmms, sendussd, vb.) cevap olarak SUCESS dönülmesi mesajın aboneye başarılı bir şekilde iletildiği anlamına gelmez. Capex mesajı başarılı bir şekilde almıştır, mesajın istek parametreleri ve sentaksı doğru demektir. Mesajın gönderildiği abonenin blacklist'te olması veya ücretlendirilememesi gibi durumlarda 3. parti bunu iletim raporundaki "deliveryreasoncode" alanından anlayabilir. Uygulamalar gelen mesajları ve iletim raporlarını toplamak için 2 yöntem kullanabilirler. 2.10.1. Poll Interface Thirdparty uygulaması belirli aralıklarla gelen mesajları almak için getreceivedsms metodunu çağırır, bu şekilde uygulamaya gelen kutusundaki bütün mesajlar cevapta liste olarak döndürülür. Bakınız bölüm 4.3. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 24 / 107
2.10.2. Push Interface Thirdparty uygulama mesajlar geldikçe kendi endpoint'ine atılmasını isteyebilir. Bunun için startsmsnotification veya startmmsnotification metodlarını kullanarak bir NotifyURL belirtir.mesajlar yada iletim raporları geldikçe bu URL'den uygulamaya ulaştırılır. Bakınız bölüm Error! Reference source not found. veya Error! Reference source not found.. Uygulamaya bağlantı hatası sebebiyle ulaştırılamayan mesajlar veya iletim raporları tekrar gönderilmez, 3. parti "polling" interface'i kullanarak gelip kendisi alır. 2.10.3. SenderAddress Bu değer uygulamanın, servis kısa numarası veya servis uzun numarasıdır. Gönderilen SMS'te görüntülenecek olan Gönderici adını ifade eder, alphanumeric bir değerdir, FormParam olarak verilir. senderaddress Örnek Kısa numara 7070 Uzun numara tel:+90543xxxxxxx 2.10.4. SenderName Bu değer uygulamanın, izin verilen alphanumeric adres setinden oluşmalı. Gönderilen mesaj (USSD,SMS,MMS)'da görüntülenecek olan Gönderici adını ifade eder, alphanumeric bir değerdir. SenderName varken senderaddress in olup olmamasına bakılmaz, originator olarak sendername setlenir. 2.10.5. RegistrationId İki yöntemi kullanırken de uygulamayı ve kısa numarasını belirlemek için bir registrationid değeri kullanılır. Bu değer uygulamanın service idsi, kısa numarası yada uzun numarası olabilir. RegistrationId ServiceId Örnek sid:1000000006 Kısa numara 7070 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 25 / 107
Uzun numara tel:+90543xxxxxxx 2.10.6. Mesaj iletim raporu değerleri SMS,MMS, USSD mesajlaşmalarında mesaj iletim raporlarında gelen deliverystatus değeri aşağıdakilerden biri olabilir. SMS, WapPush, MMS veya USSD mesajı gönderimi esnasında receiptrequest parametresi "true" olarak gönderilmişse iletim raporu uygulamaya iletilir. Aksi taktirde iletim raporu uygulamaya iletilmeyecektir, varsayılan değeri "false" dur. Delivery Status DeliveredToNetwork DeliveredToTerminal DeliveryImpossible DeliveryUncertain MessageWaiting 2.10.7. Mesaj iletim sonucu SMS,WapPush, MMS, USSD mesajlaşmalarında mesaj iletim raporlarında gelen deliveryreasoncode değeri mesajın iletilip iletilmediğini belirtir. Sıfır olması durumunda mesaj başarılı bir şekilde iletilmiştir. Bu parametreye bakılarak mesajın iletilememesinin sebebi anlaşılabilir, hata kodları Tablo 3'te açıklanmıştır. 2.10.8. Saat Bazlı Mesaj Atımı Engellenmesi 1. Mesajlaşma apileri kullanılarak (sendsms etc) atılan mesajlar (sms/wappush/mms/ussd) black hour içinde atılmaya çalışıldaysa hata mesajı alacaktır.. 2. Ücretlendirerek mesaj gönderiminde, içeriğin iletim zamanları varsayılan black hour zamanlarını ezer. 3. Örneğin chat servisi yazılacak bir uygulamada, iletim zamanları isteğe göre ayarlanmış içerikle ücretlendirerek sms gönderimi yapılmalıdır. Sms gönderme tek başına kullanılırsa black Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 26 / 107
hour hatası alabilir. 4. Kullanıcıdan gelen mesaja karşı atılan karaliste, ücretlendirme ve hata mesajları black hour a takılmayacaktır. 5. Takip sisteminde atılması gereken mesajlar black hour a takılmayacaktır. Takip edilmek istenen kişinin onay mesajından sonraki mesajlar black hour a takılabilir. 6. Abonelik API metodlarının notifikasyon mesajları abone olunan içeriğin iletim zamanlarına göre gönderilecektir. 7. Ücretlendirme ve iade api lerinin notifikasyon mesajları içeriğinin iletim zamanlarına göre atılacaktır.. 8. Abone onayı (aoc) mesajları black hour a takılacaktır.. 9. Acil içerik olan içeriklerde black hour uygulaması olmayacaktır. 2.11. Rest wadl ve Soap wsdl Attachments altında rest ve soap için gerekli wadl ve wsdl dökümanlarını, ve rest metodlarının listesini bulabilirsiniz. 2.12. WSDL'den kod oluşturulması SDF üzerinden ürettiğimiz ve WSDL ını verdiğimiz tüm servisler Standard JDK paketi ile birlikte gelen WSImport aracı ile test edilmektedir. Örnek: (c:\program Files\Java\jdk1.6.0_26\bin\wsimport.exe D:\ConsentResponseNotificationV2.wsdl ) Bu WSDL ların hem Axis2 hem de JAXWS speclerine uygun kod üretebildiği JDK ile gelen wsimport ve popüler test uygulaması SOAPUI ile de test edilmektedir. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 27 / 107
3. Abone Profili API metodları Abone Profili API metodları uygulamaların abonelere ait özelliklerini doğrulamak için kullanılan bir API metodları grubudur. Abonenin belirtilen koşulları sağlaması durumunda olumlu cevap dönülürken bunun dışında kalan tüm durumlarda olumsuz cevap dönülür. 20 adet doğrulama servisi mevcuttur. Doğrulama servisi yapılan anlaşmaya göre TCKNO, Telefon numarası veya opaqueid üzerinden gerçeklenebilir. Rest ve SOAP desteği mevcuttur. Doğrulama isteklerine true/false değerleri dönülür. True değeri sorguya ait tüm koşulların sağlandığını gösterirken, diger tüm durumlarda False cevabı dönülür. Bir MSISDN için yapılan IsMale sorgusu belirtilen MSISDN'e ait aktif bir abonelik var ise ve bu abonenin cinsiyeti Erkek ise olumlu cevap dönecektir. Bu API grubu ile açılan API metodları şunlardır: Metod Adı REST SOAP Sağlayan Kullanan Faturalı abone X X CEP 3. parti servis Ön ödemeli Abone X X CEP 3. parti servis Abone Aktiflik Durumu X X CEP 3. parti servis Abone Tüzel Kişiliği X X CEP 3. parti servis Abone Yaşı X X CEP 3. parti servis Abone Cinsiyeti X X CEP 3. parti servis Tarife Durumu X X CEP 3. parti servis Abone Segment Durumu X X CEP 3. parti servis FreeZone Durumu X X CEP 3. parti servis Doğum Günü Sorgulama X X CEP 3. parti servis Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 28 / 107
3.1. Faturalı Abone Abonenin Faturalı olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapexsubscriberid RestCapexSubscriberId Evet 2.4 de açıklanmıştır. Uygulamada subscriber ın id sidir. kullanılacak Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve faturalı ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.1.1. REST arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//queryispostpaid Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/queryispostpaid HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 29 / 107
Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", } "nickname":null, "usageid":4352 Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 81 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":4352,"response":true} 3.1.2. SOAP arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:queryispostpaid> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname/> <usageid/> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 30 / 107
</capexsubscriberid> </capexsubscriberid> </v2:queryispostpaid> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:queryispostpaidresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>true</response> <usageid>12375</usageid> </return> </ns:queryispostpaidresponse> </soapenv:body> </soapenv:envelope> 3.2. Ön Ödemeli Abone Abonenin ön ödemeli olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapexsubscriberid RestCapexSubscriberId Evet 2.4 de açıklanmıştır. Uygulamada subscriber ın id sidir. kullanılacak Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 31 / 107
resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve ön ödemeli ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.2.1. REST Arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//queryisprepaid Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/queryisprepaid HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", "nickname":null, "usageid":4352 }Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 82 Server: Jetty(6.1.25) Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 32 / 107
{"result":{"resultcode":0,"resultdesc":"success"},"usageid":4352,"response":false} 3.2.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:queryisprepaid> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname></nickname> <usageid>151</usageid> </capexsubscriberid> </v2:queryisprepaid> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:queryisprepaidresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>false</response> <usageid>151</usageid> </return> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 33 / 107
</ns:queryisprepaidresponse> </soapenv:body> </soapenv:envelope> 3.3. Abone Aktiflik Durumu Abonenin Vodafone aboneliğinin aktif olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapexsubscriberid RestCapexSubscriberId Evet 2.4 de açıklanmıştır. Uygulamada subscriber ın id sidir. kullanılacak Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.3.1. REST arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//queryactivestatus Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/queryactivestatus HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 34 / 107
Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", "nickname":null, "usageid":null }Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 82 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":13019,"response":true} 3.3.2. SOAP arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:queryactivestatus> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname></nickname> <usageid>151</usageid> </capexsubscriberid> </v2:queryactivestatus> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 35 / 107
</soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:queryactivestatusresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>true</response> <usageid>151</usageid> </return> </ns:queryactivestatusresponse> </soapenv:body> </soapenv:envelope> 3.4. Abone Tüzel Kişiliği Abonenin bireysel müşteri olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapex Subscribe rid RestCape xsubscrib erid Evet 2.4 de açıklanmıştır. Uygulamada kullanılacak subscriber ın id sidir. Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve abone bireysel müşteri ise true cevabı döner, aksi Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 36 / 107
takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.4.1. REST Arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//queryisindividual Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/queryisindividual HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", "nickname":null, "usageid":4352 }Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 81 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":4352,"response":true} Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 37 / 107
3.4.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:queryisindividual> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname></nickname> <usageid>151</usageid> </capexsubscriberid> </v2:queryisindividual> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:queryisindividualresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>true</response> <usageid>151</usageid> </return> </ns:queryisindividualresponse> </soapenv:body> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 38 / 107
</soapenv:envelope> 3.5. Abone Yaşı Abonenin yaşının verilen değerden küçük olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapex Subscribe rid RestCape xsubscrib erid Evet 2.4 de açıklanmıştır. Uygulamada kullanılacak subscriber ın id sidir. age int Evet Abone yaşı Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve abone yaşı belirtilen değerden küçük veya eşit ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.5.1. REST Arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//queryage Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/queryage?age=123 HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 39 / 107
serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", "nickname":null, "usageid":null }Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 82 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":13018,"response":true} 3.5.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:queryage> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname></nickname> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 40 / 107
<usageid></usageid> </capexsubscriberid> <age>14</age> </v2:queryage> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:queryageresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>true</response> <usageid>12359</usageid> </return> </ns:queryageresponse> </soapenv:body> </soapenv:envelope> 3.6. Abone Cinsiyeti Abonenin cinsiyetinin "Bay" olup olmadığını kontrol eden doğrulama servisidir. Cinsiyetin "Bayan" olup olmadığının kontrolü queryactivestatus=true ve queryismale=false sorgularıyla yapılmalıdır. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapex Subscribe rid RestCape xsubscrib erid Evet 2.4 de açıklanmıştır. Uygulamada kullanılacak subscriber ın id sidir. Dönüş Degerleri Adı Veri Tipi Zorunlu Açıklama Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 41 / 107
resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve Cinsiyet "Bay" ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.6.1. REST Arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//queryismale Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/queryismale HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", "nickname":null, "usageid":4352 }Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 81 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":4352,"response":true} Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 42 / 107
3.6.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:queryismale> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname/> <usageid/> </capexsubscriberid> </v2:queryismale> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:queryismaleresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>true</response> <usageid>12374</usageid> </return> </ns:queryismaleresponse> </soapenv:body> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 43 / 107
</soapenv:envelope> 3.7. Tarife Durumu Abonenin parametre olarak verilen pakette olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapex Subscribe rid RestCape xsubscrib erid Evet 2.4 de açıklanmıştır. Uygulamada kullanılacak subscriber ın id sidir. packageid String Evet Kullanıcının paket id'si.. Abone tipine göre farklı değerler mevcut ise karakteriyle birleştirilerek geçirilir. Örnek: CPK12 SPK14 duration int Hayır Eğer pozitif bir değer verildiyse abonenin belirtilen süreden beri bu pakette olup olmadığı kontrol edilir. Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve verilen pakette ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.7.1. REST Arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//querypackage Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 44 / 107
Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/querypackage?duration=4&packageid=1312 HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", "nickname":null, "usageid":null }Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 82 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":13015,"response":true} 3.7.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ver="http://verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <ver:authentication ver:user="hilal@1000000064" ver:password="abc123def" ver:sessionid="" ver:serviceid=":1005000063"/> </soapenv:header> <soapenv:body> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 45 / 107
<ver:querypackage> <enduserid>tel:+90542xxxxxxx</enduserid> <packageid>dummypackageid</packageid> <duration>30</duration> </ver:querypackage> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:querypackageresponse xmlns:ns="http://verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>false</response> </return> </ns:querypackageresponse> </soapenv:body> </soapenv:envelope> 3.8. Abone Segment Durumu Abonenin belirtilen segment'te olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapexsubscriberid RestCapexSubscriberId Evet 2.4 de açıklanmıştır. Uygulamada kullanılacak subscriber ın id sidir. segment String Evet Segment bilgisi. Abone tipine göre farklı değerler mevcut ise karakteriyle birleştirilerek geçirilir. Örnek: CSK12 SSK14 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 46 / 107
Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve numara taşınabilirliliği ile Vodafone'a taşınmış ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.8.1. REST Arayüzü Rest URL: http://172.28.138.129:8000/2/0/verification//querysegment Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/querysegment?segment=dumseg HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", "nickname":null, "usageid":4352 }Örnek Rest Cevap Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 47 / 107
HTTP/1.1 200 OK Content-Type: application/json Content-Length: 81 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":4352,"response":true} 3.8.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:querysegment> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname></nickname> <usageid>151</usageid> </capexsubscriberid> <segment>1</segment> </v2:querysegment> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:querysegmentresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 48 / 107
<resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>true</response> <usageid>151</usageid> </return> </ns:querysegmentresponse> </soapenv:body> </soapenv:envelope> 3.9. FreeZone Durumu Abonenin FreeZone üyesi olup olmadığını kontrol eden doğrulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapex Subscribe rid RestCape xsubscrib erid Evet 2.4 de açıklanmıştır. Uygulamada kullanılacak subscriber ın id sidir. duration int Hayır Aboneliğin sorgusunun çalışacağı zaman süresi (Gün) Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonelik aktif ve FreeZone özelliği var ise true cevabı döner, aksi takdirde false cevabı dönülür usageid Long Evet UsageId bilgisidir. 3.9.1. REST Arayüzü Rest URL: Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 49 / 107
http://172.28.138.129:8000/2/0/verification//queryisfreezone Örnek Rest İstek POST http://172.25.23.74:8100/2/0/verification/queryisfreezone?duration=5 HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000043 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 153 { "enduserid":"acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmi dvtzhs91vnnb4gorinocf2ldota==", } "nickname":null, "usageid":4352 Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 81 Server: Jetty(6.1.25) {"result":{"resultcode":0,"resultdesc":"success"},"usageid":4352,"response":true} 3.9.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 50 / 107
<v2:queryisfreezone> <capexsubscriberid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91v NnB4GOrInoCF2LDoTA==</endUserId> <nickname/> <usageid/> </capexsubscriberid> <duration>2</duration> </v2:queryisfreezone> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:queryisfreezoneresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <response>true</response> <usageid>12373</usageid> </return> </ns:queryisfreezoneresponse> </soapenv:body> </soapenv:envelope> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 51 / 107
3.10. Doğum Günü Sorgulama Abonenin doğum tarihinin verilen tarihler arasında olup olmadığını kontrol eden sorgulama servisidir. İstek Parametreleri Adı Veri Tipi Zorunlu Size Açıklama restcapex Subscribe rid RestCape xsubscrib erid Evet 2.4 de açıklanmıştır. Uygulamada kullanılacak subscriber ın id sidir. startdate String Evet DD.MM Sorgulanmak istenen doğum tarih aralığı başlangıcı enddate String Evet DD.MM Sorgulanmak istenen doğum tarih aralığı sonudur. Örnek: startdate=05.12 ve enddate=17.01 ise enddate daha küçük olduğundan bir sonraki yıl olduğu farz edilir, sistem tarafından startdate=05.12.(xyıl) olarak yorumlanırken enddate=17.01.(x+1 yıl) olarak yorumlanır. Dönüş Değerleri Adı Veri Tipi Zorunlu Açıklama resultcode long Evet Capex'in döndüğü sonuç değeri resultdescription String Evet Capex'in döndüğü sonuca dair açıklama response boolean Evet Abonenin doğum tarihi sorgulanan aralıkta ise evet, aksi taktirde hayir cevabı döner. usageid Long Evet UsageId bilgisidir. 3.10.1. REST Arayüzü Rest URL: http://127.0.0.1:8000/2/0/verification/querybirthday Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 52 / 107
Örnek Rest İstek POST http://127.0.0.1:8000/2/0/verification/querybirthday?startdate=11.11&enddate=30.12 HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic aglsywxamtawmdawmda2ntpiawxhbde5odm= serviceid: :1001000002 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8000 Content-Length: 73 { "enduserid":"tel:+90542xxxxxxx", "nickname":null, "usageid":4352 } Örnek Rest Cevap HTTP/1.1 200 OK Content-Type: application/json Content-Length: 82 Server: Jetty(6.1.25) { "result": { "resultcode": 0, "resultdesc": "Success" }, "usageid": 4352, "response": false } Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 53 / 107
3.10.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="hilal@1000000065" v2:password="hilal1983" v2:sessionid="" v2:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v2:querybirthday> <capexsubscriberid> <usageid>12</usageid> <enduserid>tel:+90542xxxxxxx</enduserid> <nickname xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> </capexsubscriberid> <startdate>12.12</startdate> <enddate>17.01</enddate> </v2:querybirthday> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:querybirthdayresponse xmlns:ns="http://v2.soap.verification.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 54 / 107
<response>true</response> <usageid>12</usageid> </return> </ns:querybirthdayresponse> </soapenv:body> </soapenv:envelope> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 55 / 107
4. SMS API Metodları SMS API metodları aşağıdaki tabloda bulunabilir. Metod Adı REST SOAP Sağlayan Kullanan SMS Gönderimi (OneAPI yöntemi) X X CEP 3. parti servis Ücretlendirerek SMS gönderimi X X CEP 3. parti servis Wap Push Gönderimi (OneAPI yöntemi) X X CEP 3. parti servis Ücretlendirerek Wap Push gönderimi X X CEP 3. parti servis İleti Raporları Toplu Alımı X X CEP 3. parti servis İleti Raporları Alımını Başlatma X X CEP 3. parti servis İleti Raporları Alımını Durdurma X X CEP 3. parti servis İleti Raporu İtme X X 3. parti servis CEP SMS Mesajını Alma X X CEP 3. parti servis SMS Mesaj Alımını Başlatma X X CEP 3. parti servis SMS Mesaj Alımını Durdurma X X CEP 3. parti servis SMS Mesajı İtme X X 3. parti servis CEP Konum Tabanlı Servisler için Abone Maskeleme Geliştirilmiş yeteneklerden birisi de konum takip içeriği sunan servislerde kullanılan abone kimliği maskeleme özelliğidir. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 56 / 107
CEP Friend Finder 05425444444 Takip 05455888888 SMS from opaquea «Takip opaqueb» SMS «05455888888 şu anda Dolmabahçe de» SMS «acr:opaqueb şu anda Dolmabahçe de» CEP takip servislerine özel abone kimliği maskeleme özelliği sunmaktadır. Maskeleme hem kullanıcılar tarafından atılan mesajlarda; hem de üçüncü parti uygulamalardan CEP e yapılan SMS Gönderme (OneApi) isteklerinde yapılmaktadır. Kullanıcı tarafından atılan mesajlarda, mesajın içeriği <takip anahtar kelimesi> <msisdn> formatında olmalıdır. Örneğin: takip 0542xxxxxxx. CEP bu mesajı üçüncü parti uygulamalara çıkarırken <takip anahtar kelimesi> <opaque id> olarak çıkarır. Örnek: takip acr:ct6s Ct6S162pnQ+jEiw5RQZhW162==. Üçüncü parti uygulamaları <opaque id> kısmını aboneyi tanımlayan belirteç değerinde (enduserid) kullanabilir. Maskeleme süreci ve hata durumları ile ilgili kullanıcıya notifikasyon mesajları atılır. Sms Gönderme (OneApi) isteklerinde ise %<opaque b>% <message text> şeklinde olan mesaj içeriğini CEP <msisdn> <message text> olarak değiştirir. Yani maskelemesi çözülmek istenen abone belirteci %<opaque b>% şeklinde girilmelidir. Örnek: %acr:ct6s Ct6S162pnQ+jEiw5RQZhW162==% Dolmabahçe de.. CEP bu mesajı 0542xxxxxxx Dolmabahçe de. şeklinde çevirip kulanıcıya atacaktır. Maskeleme çözümleme işleminde bir sorun olursa ilgili hata kodu belirtilir. 4.1. SMS Gönderimi (OneAPI yöntemi) Uygulama SMS gönderiminde kullanılır. İletim raporu isteyip istemediğini parametre olarak belirtebilir, varsayılan hali uygulamanın iletim rapor istemediği yönündedir. Uygulamaya requestid dönülür, uygulama bu Id ile iletim raporu sorgusu yapabilir. Eğer istek sonucu başarısız ise kullanıcıya başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametreleri Adı Veri Tipi Zorunlu Açıklama restsmsoutboun dparameters RestSmsOutboundPa rameters E Sms gönderilirken kullanılacak parametreler. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 57 / 107
RestSmsOutboundParameters Parametre Veri Tipi Zorunlu Boyut Açıklama senderaddress String E 2.7.3'de açiklanmistir. restcapexsubscriberid List<RestCapexSubscriberId> E Max. 50 adres alabilir. Uygulamanın SenderAddress i, PathParam olarak verilir Kısa mesaj gönderilecek olan abonenin restcapexsubscriberid si, FormParam olarak verilir. message String E 1530 byte SMS ile gönderilecek olan mesaj içeriği, FormParam olarak verilir. senderaddress String E 2.7.3'de açiklanmistir. Uygulamanın SenderAddress si, FormParam olarak verilir. clientcorrelator String H 30 byte Ardarda birden fazla istek yapılmasını önler, FormParam olarak verilir. notifyurl String H 512 byte Gelen iletim raporlarını uygulamaya iletmek için kullanılacak olan URL'dir, FormParam olarak verilir. sendername String H 2.7.4'de açılanmıştır. Uygulamanın SenderName i, FormParam olarak verilir. receiptrequest Boolean H - İletim raporu talep edilip edilmediğini ifade eder, varsayılan değeri false'dur. FormParam olarak verilir. requestchannel String H 3 byte Default SMS Dönüş Değerleri Parametre Veri Tipi Açıklama Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 58 / 107
requestid String Başarılı ise requestid, hata durumlarında ERROR dönülür. Error information String Sorgu sonucunun başarısız olduğu durumda dönülür Error messageid String Sorgu başarısızsa hata kodunu içerir Error text String Hata açıklaması yer alır. restcapexsubscriberidlist List<RestCapexSubscriberId> Uygulamada kullanılan subscriber id nin listesidir. 4.1.1. REST Arayüzü REST URL http://127.0.0.1:8000/2/0/smsmessaging/outbound/{senderaddress}/requests Örnek Rest İstek POST http://127.0.0.1:8000/2/0/smsmessaging/outbound/131971/requests HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumzu= serviceid: :1001000162 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 127.0.0.1:8000 Content-Length: 513 {"restcapexsubscriberid":[{"enduserid":"tel:+90542xxxxxxx","nickname":"","usageid":3},{"e nduserid":"tel:+90542xxxxxxx","nickname":"","usageid":59}],"message":"hi","senderaddressp aram":"131971","clientcorrelator":"41872694","notifyurl":"https://172.28.138.59:9443/dene me/myservlet","sendername":"vodafone","receiptrequestparam":"true","messagetype":"","requ estchannel":"web"} Örnek Rest Cevap: HTTP/1.1 201 Created Content-Type: application/json Location: http://127.0.0.1:8000/2/0/smsmessaging/outbound/131971/requests/sdf113391362991 Content-Length: 268 Server: Jetty(6.1.25) { "restcapexsubscriberidlist": [ Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 59 / 107
{ "usageid": 3, "nickname": "", "enduserid": "tel:+90542xxxxxxx" }, { "usageid": 59, "nickname": "", "enduserid": "tel:+90542xxxxxxx" } ], "resourcereference": {"resourceurl": "developer.vodafone.com/2/0/smsmessaging/outbound/131971/requests/sdf113391362991"} } 4.1.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.sms.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="sultan@1000000062" v2:password="password" v2:sessionid="" v2:serviceid=":1001000162"/> </soapenv:header> <soapenv:body> <v2:sendsms> <!--1 or more repetitions:--> <capexsubscriberidlist> <enduserid>tel:+90542xxxxxxx</enduserid> <nickname></nickname> <usageid>888</usageid> </capexsubscriberidlist> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 60 / 107
<sendername></sendername> <senderaddress>131971</senderaddress> <message>hi</message> <clientcorrelator></clientcorrelator> <notifyurl></notifyurl> <messagetype></messagetype> <receiptrequest></receiptrequest> <requestchannel></requestchannel> </v2:sendsms> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:sendsmsresponse xmlns:ns="http://v2.soap.sms.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <capexsubscriberidlist> <enduserid>tel:+90542xxxxxxx</enduserid> <nickname/> <usageid>888</usageid> </capexsubscriberidlist> <requestid>sdf113384816371</requestid> </return> </ns:sendsmsresponse> </soapenv:body> </soapenv:envelope> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 61 / 107
4.2. İletim Raporları Alımı Atılmış olan SMSlerin iletim raporları sorgulanablir. İstek Parametereleri Parametre Veri Tipi Zorunlu Size Açıklama senderaddress String E 2.7.3'te açiklanmistir. Uygulamanın SenderAddress'i, PathParam olarak verilir requestidentifier String E 30 byte sendsms veya sendwappush sonucu uygulamaya dönülen requestid, PathParam olarak verilir. Dönüş Değerleri Parametre Veri Tipi Açıklama deliveryinfo List<RestDeli veryinfo> Başarılı ise Mesajların listesi dönülür, hata durumlarında ERROR dönülür. resourceurl String Bu mesajın referans URL'ini belirtir, uygulama mesajın durumunu bu linkten takip edebilir. Alındı Bilgisi (Delivery Info) Parametre Veri Tipi Açıklama address String Mesajın gönderilmiş olduğu son kullanıcınnın EndUserId sidir. deliverystatus String Mesajın iletilip iletilmediğini gösteren durumunu ifade eder deliveryreasoncode Integer Mesajın iletilememsi durumunda sorunun sebebini belirtir,başarılı ise değeri sıfır. usageid Long UsageId bilgisidir. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 62 / 107
4.2.1. REST Arayüzü Rest URL: http://127.0.0.1:8000/2/0/smsmessaging/outbound/{senderaddress}/requests/{requestidentifier}/d eliveryinfos Örnek Rest İstek GET http://127.0.0.1:8000/2/0/smsmessaging/outbound/131971/requests/sdf113385454451/deliveryi nfos HTTP/1.1 Accept-Encoding: gzip,deflate Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumzu= serviceid: :1001000162 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 127.0.0.1:8000 Örnek Rest Cevap: HTTP/1.1 200 OK Content-Type: application/json Content-Length: 364 Server: Jetty(6.1.25) {"deliveryinfolist": { "resourceurl": "developer.vodafone.com/2/0/smsmessaging/outbound/131971/requests/sdf113391366721/deliver yinfos", "deliveryinfo": [ }, { "address": "tel:+90542xxxxxxx", "deliverystatus": "DeliveredToTerminal", "usageid": 3, "deliveryreasoncode": 0 { "address": "tel:+90542xxxxxxx", "deliverystatus": "DeliveredToTerminal", Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 63 / 107
"usageid": 59, "deliveryreasoncode": 0 } ] }} 4.2.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.sms.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="user@1000000062" v2:password="password" v2:sessionid="" v2:serviceid=":1001000162"/> </soapenv:header> <soapenv:body> <v2:getsmsdeliverystatus> <requestidentifier>sdf113391321451</requestidentifier> <senderaddress>131971</senderaddress> </v2:getsmsdeliverystatus> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:getsmsdeliverystatusresponse xmlns:ns="http://v2.soap.sms.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <deliveryinformationlist> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 64 / 107
<address>tel:+90542xxxxxxx</address> <chargereferencecode>2389206</chargereferencecode> <deliveryreasoncode>0</deliveryreasoncode> <deliverystatus>deliveredtoterminal</deliverystatus> <usageid>56</usageid> </deliveryinformationlist> </return> </ns:getsmsdeliverystatusresponse> </soapenv:body> </soapenv:envelope> 4.3. SMS Mesajını Alma Son kullanıcıdan gelen SMSleri uygulamaya çıkarır. Eğer kaydolmuş bir URL mevcut ise her gelen iletim raporu uygulamaya push edilir. Eğer istek sonucu başarısız ise kullanıcıya başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametereleri Parametre Veri Tipi Zorunlu Size Açıklama registrationid String E 30 byte Uygulamanın RegistrationId i. PathParam olarak verilir maxbatchsize int E - Uygulama bir kerede dönülecek maximum mesaj miktarını belirtir, QueryParam olarak verilir. Dönüş Değerleri Parametre Veri Tipi Açıklama inboundsmsmessage List<RestInboundSMSMessage> Başarılı ise Mesajların listesi dönülür, hata durumlarında ERROR dönülür. numberofmessagesinthisbatch int Başarılı ise üstteki listenin içinde kaç mesaj olduğu dönülür, hata durumlarında ERROR dönülür. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 65 / 107
totalnumberofpendingmessages int Başarılı ise geriye kalan mesajların sayısı dönülür, hata durumlarında ERROR dönülür. resourceurl String Mesajlara ulaşılabilecek URL (rest için geçerli) Error information String Sorgu sonucunun başarısız olduğu durumda dönülür Error messageid String Sorgu başarısızsa hata kodunu içerir Error text String Hata açıklaması yer alır. Inbound SMS Message Tipi Parametre Veri Tipi Açıklama datetime long İsteğin yapıldığı tarih message String Mesaj içeriği messageid long Mesaj Id senderaddress String Onay isteğinde bulunan uygulamanın(kullanıcının) adresi resourceurl String Bu mesaja ait URL (rest için geçerli) restcapexsubscriberid RestCapexSubscriberId Uygulamada kullanılacak subscriber ın id sidir. 4.3.1. REST Arayüzü Rest URL: http://127.0.0.1:8000/2/0/smsmessaging/inbound/registrations/{registrationid}/messages Örnek Rest İstek GET http://localhost:8000/2/0/smsmessaging/inbound/registrations/23/messages?maxbatchsize=23 HTTP/1.1 Accept-Encoding: gzip,deflate Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumtizna== serviceid: :2001000001 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 66 / 107
User-Agent: Jakarta Commons-HttpClient/3.1 Host: localhost:8000 Örnek Rest Cevap: HTTP/1.1 200 OK Content-Type: application/json Transfer-Encoding: chunked Server: Jetty(6.1.25) { "resourceurl":"developer.vodafone.com/2/0/smsmessaging/inbound/registrations/23/messages", "inboundsmsmessage": [ {"message":"hayri","resourceurl":"developer.vodafone.com/2/0/smsmessaging/inbound/registr ations/23/messages/sdf11318079270694", "messageid":"sdf11318079270694","senderaddress":"90543xxxxxxx","datetime":1318082074155," restcapexsubscriberid":{"enduserid":"tel:+90542xxxxxxx","nickname":"","usageid":3}}, {"message":"hayri","resourceurl":"developer.vodafone.com/1/smsmessaging/inbound/registrat ions/23/messages/sdf11318079270695", "messageid":"sdf11318079270695","senderaddress":"90543xxxxxxx","datetime":1318082083693," restcapexsubscriberid":{"enduserid":"tel:+90542xxxxxxx","nickname":"","usageid":4}}, {"message":"hayri","resourceurl":"developer.vodafone.com/1/smsmessaging/inbound/registrat ions/23/messages/sdf11318079270696", "messageid":"sdf11318079270696","senderaddress":"90543xxxxxxx","datetime":1318082091668," restcapexsubscriberid":{"enduserid":"tel:+90542xxxxxxx","nickname":"","usageid":5}} } ], "numberofmessagesinthisbatch":3, "totalnumberofpendingmessages":0, 4.3.2. SOAP Arayüzü Örnek Soap İstek Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 67 / 107
<soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v2="http://v2.soap.sms.capabilityexposure.services.oksijen.com"> <soapenv:header> <v2:authentication v2:user="user@companyid" v2:password="password" v2:sessionid="" v2:serviceid=":serviceid"/> </soapenv:header> <soapenv:body> <v2:getreceivedsms> <registrationid>131971</registrationid> <maxbatchsize>3</maxbatchsize> </v2:getreceivedsms> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:getreceivedsmsresponse xmlns:ns="http://v2.soap.sms.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <numberofmessagesinthisbatch>1</numberofmessagesinthisbatch> <smslist> <datetime>2012-01-10t13:00:39.000+02:00</datetime> <capexsubscriberid> <enduserid>131971</enduserid> <nickname xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <usageid>12573</usageid> </capexsubscriberid> <message>send corporate</message> <messageid>sdf113261932401</messageid> <senderaddress>tel:+90542xxxxxxx</senderaddress> </smslist> <totalnumberofpendingmessages>0</totalnumberofpendingmessages> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 68 / 107
</return> </ns:getreceivedsmsresponse> </soapenv:body> </soapenv:envelope> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 69 / 107
5. Konum ve Coğrafi Bilgi API Metodları Lokasyon apisi web uygulamalarının Vodafone networkündeki bir mobil cihazın yerinin sorgulanması için kullanılır. Bir ya da birden fazla kullanıcı numarası verilerek enlem,boylam olarak konum öğrenilebilir. REST ve SOAP olarak açılmış bir servistir. Bu API grubuyla açılan metodlar şu şekildedir: Metod Adı REST SOAP Sağlayan Kullanan Konum Sorgusu X X CEP 3. parti servis Grup Konum Sorgusu X X CEP 3. parti servis Adres Sorgusu X X CEP 3. parti servis İlgi Noktası (POI) sorgulama X X CEP 3. parti servis Rota Sorgulama X X CEP 3. parti servis 5.1. Konum Sorgusu Vodafone kullanıcının numarası verilerek bulunduğu koordinatlar öğrenilir. Eğer istek sonucu başarısız ise 3. paritye başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametereleri Parametre Veri Tipi Zorunl u Size Açıklama address List <RestCapexSubscriberId> E 30 adet adres alabilir. Lokasyonu bulunmak istenen abonelerin listesi requester RestLocationSubscriberI d H Lokasyonu almak isteyen abonenin ID si Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 70 / 107
requestedaccuracy int H - Metre cinsinden istenen hassasiyet değeri acceptableaccurac y int H - Metre cinsinden istenen hassasiyet değeri maximumage int H - Metre cinsinden istenen hassasiyet değeri responsetime int H - Metre cinsinden istenen hassasiyet değeri tolerance int E - NoDelay,LowDelay,DelayToleran t RestCapexSubscriberId Parametre Veri Tipi Zorunlu Size Açıklama enduserid String E 20 byte Lokasyonu alınmak istenen abonenin EndUserid si usageid Long H Bağlanmak istenen akışa ait usageid bilgisidir. Verilmemesi durumunda yeni akış kabul edildiği için yeni bir usageid üretilip cevapta dönülür. nickname String H Lokasyonu alınmak istenen abonenin nickname ini ifade eder. RestLocationSubscriberId Parametre Veri Tipi Zorunlu Size Açıklama enduserid String E 20 byte Lokasyon isteğinde bulunan abonenin EndUserid si nickname String H Lokasyon isteğinde bulunan nickname ini ifade eder. Dönüş Değerleri Parametre Veri Tipi Açıklama Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 71 / 107
address String Abonenin opaqueid si accuracy int Hassasiyet altitude float Yükseklik latitude float Enlem longitude float Boylam timestamp String Sorgu zamanı locationretrievalstatus String Başarılı ise RETRIVED, hata durumlarında ERROR dönülür. usageid Long Akışı bağlamak için dönülen usageid bilgisidir. Error information String Sorgu sonucunun başarısız olduğu durumda dönülür Error messageid String Sorgu başarısızsa hata kodunu içerir Error text String Hata açıklaması yer alır. 5.1.1. REST Arayüzü Rest URL: http://127.0.0.1:8000/3/0/location/queries/location Örnek Rest İstek POST http://127.0.0.1:8000/3/0/location/queries/location?requestedaccuracy=100 HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic c2vsaw1lqdewmdawmdawnjy6u2vsateymzq= serviceid: :1001000008 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 127.0.0.1:8000 Content-Length: 225 { "requester": {"enduserid":"tel:+90542xxxxxxx","nickname":"seli"}, "address": [{"enduserid":"tel:+90543xxxxxxx","nickname":"seli","usageid":45},{"enduserid":"tel:+9054 2xxxxxxx","nickname":"sulti","usageId":46}] Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 72 / 107
} Örnek Rest Cevap: HTTP/1.1 200 OK Content-Type: application/json Content-Length: 513 Server: Jetty(6.1.25) {"terminallocation": [ { "address": "tel:+90543xxxxxxx", "currentlocation": { "timestamp": "2012-06-1T14:06:45", "accuracy": 0, "altitude": 0, "latitude": 41.10833, "longitude": 29.034119 }, "usageid": 45, "locationretrievalstatus": "Retrieved", "errorinformation": null }, { "address": "tel:+90542xxxxxxx", "currentlocation": null, "usageid": 46, "locationretrievalstatus": "NotRetrieved", "errorinformation": { "policyexception": null, "serviceexception": { "messageid": "177", "text": "Location consent is rejected.", "variables": null, "usageid": 46 } Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 73 / 107
} } ]} 5.1.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v3="http://v3.soap.location.capabilityexposure.services.oksijen.com"> <soapenv:header> <v3:authentication v3:user="hilal@1000000065" v3:password="hilal1983" v3:sessionid="" v3:serviceid=":1001000043"/> </soapenv:header> <soapenv:body> <v3:getlocation> <requester> <enduserid>acr:286002bcofj7vc8l5zm7afpmp9ujiaz1ijks44gzy72ylz9xkq0cyed+w1l5zaiqdtrj+hkf7l bnc8vgywpj8o8uz9yw==</enduserid> <nickname>eray</nickname> </requester> <address> <usageid>34</usageid> <enduserid>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidv TZhS91vNnB4GOrInoCF2LDoTA==</endUserId> <nickname>hilal</nickname> </address> <requestedaccuracy>45</requestedaccuracy> <maximumage> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 74 / 107
<metric>second</metric> </maximumage> <responsetime> <metric>second</metric> </responsetime> <tolerance>nodelay</tolerance> </v3:getlocation> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:getlocationresponse xmlns:ns="http://v3.soap.location.capabilityexposure.services.oksijen.com"> <return> <resultcode>177</resultcode> <resultdesc>location consent is rejected.</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <address>acr:286002mjvrv/jvu2uh58/eki20rgbrwe+gct6s162pnq+jeiw5rqzhwk77bt30pmidvtzhs91vnn B4GOrInoCF2LDoTA==</address> <currentlocation> <accuracy>0</accuracy> <altitude xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <latitude>0.0</latitude> <longitude>0.0</longitude> <timestamp xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> </currentlocation> <reportstatus>notretrieved</reportstatus> <usageid>34</usageid> </return> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 75 / 107
</ns:getlocationresponse> </soapenv:body> </soapenv:envelope> 5.2. Grup Konum Sorgusu Vodafone kullanıcılarının numarası verilerek bulunduğu koordinatlar öğrenilir. Eğer istek sonucu başarısız ise 3. partiye başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametereleri Parametre Veri Tipi Zoru nlu Size Açıklama address List <RestCapexSubscribe rid> E 30 adet adres alabilir. 7.1 de açıklanmıştır. Lokasyonu bulunmak istenen abonelerin listesi requester RestLocationSubscri berid H 7.1 de açıklanmıştır. Lokasyonu almak isteyen abonenin ID si, requestedacc uracy acceptableac curacy int E - Metre cinsinden istenen hassasiyet değeri int H - Metre cinsinden istenen hassasiyet değeri maximumage int H - Metre cinsinden istenen hassasiyet değeri responsetime int H - Metre cinsinden istenen hassasiyet değeri tolerance int E - NoDelay,LowDelay,DelayTo lerant Dönüş Değerleri Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 76 / 107
Parametre Veri Tipi Açıklama address String Abonenin opaqueid si accuracy int Hassasiyet altitude float Yükseklik latitude float Enlem longitude float Boylam timestamp String Sorgu zamanı locationretrievalstatus String Başarılı ise RETRIVED, hata durumlarında ERROR dönülür. usageid Long Akışı bağlamak için dönülen usageid bilgisidir. Error information String Sorgu sonucunun başarısız olduğu durumda dönülür Error messageid String Sorgu başarısızsa hata kodunu içerir 5.2.1. REST Arayüzü 7.1.1 ile aynı method çağrılır. 5.2.2. SOAP Arayüzü Örnek Soap İstek <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v3="http://v3.soap.location.capabilityexposure.services.oksijen.com"> <soapenv:header> <v3:authentication v3:user="sultan@1000000062" v3:password="sultan35" v3:sessionid="" v3:serviceid=":1001000162"/> </soapenv:header> <soapenv:body> <v3:getlocationforgroup> <requester> <enduserid>tel:+90542xxxxxxx</enduserid> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 77 / 107
<nickname xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> </requester> <!--1 or more repetitions:--> <address> <enduserid>tel:+90542xxxxxxx</enduserid> <nickname xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <usageid>45</usageid> </address> <address> <enduserid>tel:+90542xxxxxxx</enduserid> <nickname xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <usageid>45</usageid> </address> <requestedaccuracy>12</requestedaccuracy> <maximumage> <metric>second</metric> </maximumage> <responsetime> <metric>second</metric> </responsetime> <tolerance>nodelay</tolerance> </v3:getlocationforgroup> </soapenv:body> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 78 / 107
</soapenv:envelope> Örnek Soap Cevap: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:getlocationforgroupresponse xmlns:ns="http://v3.soap.location.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <location> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <address>tel:+90542xxxxxxx</address> <currentlocation> <accuracy>0</accuracy> <altitude xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <latitude>41.10833</latitude> <longitude>29.034119</longitude> <timestamp>2012-06-12t13:42:52.000+03:00</timestamp> </currentlocation> <reportstatus>retrieved</reportstatus> <usageid>45</usageid> </location> <location> <resultcode>171</resultcode> <resultdesc>waiting For Location Consent</resultDesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <address>tel:+90542xxxxxxx</address> <currentlocation> <accuracy>0</accuracy> <altitude xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 79 / 107
<latitude>0.0</latitude> <longitude>0.0</longitude> <timestamp xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> </currentlocation> <reportstatus>waitingforconsent</reportstatus> <usageid>45</usageid> </location> </return> </ns:getlocationforgroupresponse> </soapenv:body> </soapenv:envelope> 5.3. Konum Onayının Durum Bilgisini Sorgulama Kullanıcı girdi olarak isteği yapan kişinin adresini (servis lokasyon sorguluyorsa boş bırakılır) ve istekde bulunulan kişinin adresini verir, sonucunda onayın durum bilgisi kullanıcıya döner. Bunun yanında sonuç değeri de kullanıcıya döndürülür, başarılı veya başarısız şeklinde. Eğer istek sonucu başarısız ise kullanıcıya başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametereleri Parametre Veri Tipi Zorunlu Size Açıklama requester RestlocationSubscriberId H 7.1 de açıklanmıştır. requested RestCapexSubscriberId E 7.1de açıklanmıştır. Lokasyonu almak isteyen abonenin ID sidir Lokasyonu bulunmak istenen abonelerin CapexSubscriberId sidir listesi Dönüş Değerleri Parametre Veri Tipi Açıklama Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 80 / 107
content String YES, NO ve NO_CONSENT olabilir. Onayın durumunu belirtir. requested String Lokasyonu bulunmak istenen abonenin adresi. requester String Lokasyonu almak isteyen abonenin EndUserId si (servis olması durumunda boştur) requesternickname String Lokasyonu almak isteyen abonenin takma adı. usageid Long Bu bilgi girdi olarak verilmediyse yeni bir akış olduğu farz edilip yeni bir usageid üretilip dönülür. Error messageid String Sorgu başarısızsa hata kodunu içerir Error text String Hata açıklaması yer alır. 5.3.1. REST Arayüzü Rest URL: http://127.0.0.1:8000/2/0/consent/location/requests/query Örnek Rest İstek POST http://172.25.23.74:8100/2/0/consent/location/requests/query HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: application/json Authorization: Basic c3vsdgfuqdewmdawmdawnji6u3vsdgfumzu= serviceid: :1001000162 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 172.25.23.74:8100 Content-Length: 161 { "requester": {"enduserid":"tel:+90542xxxxxxx","nickname":"eray"}, "address": {"enduserid":"tel:+90542xxxxxxx","nickname":"seli","usageid":46} } Örnek Rest Cevap: HTTP/1.1 200 OK Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 81 / 107
Content-Type: application/json Content-Length: 125 Server: Jetty(6.1.25) { "content": "YES", "usageid": 46, "requester": "tel:+90542xxxxxxx", "requested": "tel:+90542xxxxxxx", "requesternickname": "eray" } 5.3.2. SOAP Arayüzü Örnek Soap İstek <soap:envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:v2="http://v2.soap.location.consent.capabilityexposure.services.oksijen.com"> <soap:header> <v2:authentication v2:user="sultan@1000000062" v2:password="sultan35" v2:sessionid="" v2:serviceid=":1001000162"/> </soap:header> <soap:body> <v2:querylocationconsentresponse> <requester> <enduserid>tel:+90542xxxxxxx</enduserid> <nickname>eray</nickname> </requester> <requested> <usageid>46</usageid> <enduserid>tel:+90542xxxxxxx</enduserid> <nickname>seli</nickname> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 82 / 107
</requested> </v2:querylocationconsentresponse> </soap:body> </soap:envelope> Örnek Soap Cevap: <soapenv:envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope"> <soapenv:body> <ns:querylocationconsentresponseresponse xmlns:ns="http://v2.soap.location.consent.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <content>yes</content> <requested>tel:+90542xxxxxxx</requested> <requester>tel:+90542xxxxxxx</requester> <requesternickname>eray</requesternickname> <usageid>46</usageid> </return> </ns:querylocationconsentresponseresponse> </soapenv:body> </soapenv:envelope> 5.4. Adres Sorgusu Kullanıcı girdi olarak koordinatlarını verir, sonucunda bulunduğu adres kullanıcıya döner. Bunun yanında sonuç değeri de kullanıcıya döndürülür, başarılı veya başarısız şeklinde. Eğer istek sonucu başarısız ise kullanıcıya başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametereleri Parametre Veri Tipi Zorunlu Açıklama X Double E Enlem koordinatını belirtir Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 83 / 107
Y Double E Boylam koordinatını belirtir usageid Long H Akışı bağlamak için gerekli olan usageid Dönüş Değerleri Parametre Veri Tipi Açıklama address String Kullanıcının bulunduğu adresi döner ResultCode int Sorgu sonucunun başarılı veya başarısız olduğunu gösterir. ResultDesc String Sorgu sonucunun başarılı veya başarısız olduğunu gösterir. Başarılı ise SUCCESS, başarısız ise hata açıklaması yer alır. usageid Long Bu bilgi girdi oalrak verilmediyse yeni bir akış olduğu farz edilip yeni bir usageid üretilip dönülür. 5.4.1. SOAP Arayüzü Örnek Soap İstek: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v3="http://v3.soap.poi.capabilityexposure.services.oksijen.com"> <soapenv:header> <v3:authentication v3:user="selime@1000000066" v3:password="seli1234" v3:sessionid="" v3:serviceid=":1001000008"/> </soapenv:header> <soapenv:body> <v3:getaddress> <x>41.104838</x> <y>29.033432</y> <usageid>3</usageid> </v3:getaddress> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap: Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 84 / 107
<soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:getaddressresponse xmlns:ns="http://v3.soap.poi.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <address>turkiye, ISTANBUL, SARIYER, RESITPASA MAH.</address> <usageid>3</usageid> </return> </ns:getaddressresponse> </soapenv:body> </soapenv:envelope> 5.4.2. REST Arayüzü Rest URL: http://127.0.0.1:8000/3/0/poi/address Örnek Rest İstek: GET http://127.0.0.1:8000/3/0/poi/address?usageid=23&y=29.033432&x=41.104838 HTTP/1.1 Accept-Encoding: gzip,deflate Authorization: Basic c2vsaw1lqdewmdawmdawnjy6u2vsateymzq= serviceid: :1001000008 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 127.0.0.1:8000 Örnek Rest Cevap: HTTP/1.1 200 OK Content-Type: application/json Content-Length: 124 Server: Jetty(6.1.25) { "address": "TURKIYE, ISTANBUL, SARIYER, RESITPASA MAH.", "usageid": 23, "resultcode": 0, Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 85 / 107
"variables": null, "resultdesc": "Success" } 5.5. İlgi Noktası (POI) sorgulama Koordinat ve kategori listesi ile verilen noktaya en yakın kategorilerin bilgilerini elde edebilirsiniz. Girdi olarak kullanıcının koordinatlarını verilir, sonucunda bulunduğu adres kullanıcıya döner. Bunun yanında sonuç degeri de kullanıcıya döndürülür, başarılı veya başarısız şeklinde. Eğer istek sonucu başarısız ise kullanıcıya başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametereleri Parametre Veri Tipi Zorunlu Açıklama X Double E Enlem koordinatını belirtir Y Double E Boylam koordinatını belirtir category StringArray E Kullanıcının ilgilendiği kategori listesi Örnek: ezcaneler,hastane. Kategori listesinin tamamı Ek C de belirtilmiştir. radius int H Poi listesinin bulunmasını istediğimiz yarıçap Örnek: 2 km yarıçapındaki poileri getir poicount int E Dönen listede görmek istediğimiz poi sayısı usageid Long H Akışı bağlamak için gerekli olan usageid Dönüş Değerleri Parametre Veri Tipi Açıklama address String Kullanıcının bulunduğu adresi döner PoiList Object POI listesi dönülür. Bu listenin içerisinde şu değerler yer alır: address city country county description Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 86 / 107
distance district latitude longtitude note placename placetype street telno ResultCode int Sorgu sonucunun başarılı veya başarısız olduğunu gösterir. ResultDesc String Sorgu sonucunun başarılı veya başarısız olduğunu gösterir.başarılı ise SUCCESS, başarısız ise hata açıklaması yer alır. usageid Long Bu bilgi girdi oalrak verilmediyse yeni bir akış olduğu farz edilip yeni bir usageid üretilip dönülür. 5.5.1. SOAP Arayüzü Örnek Soap İstek: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v3="http://v3.soap.poi.capabilityexposure.services.oksijen.com"> <soapenv:header> <v3:authentication v3:user="selime@1000000066" v3:password="seli1234" v3:sessionid="" v3:serviceid=":1001000008"/> </soapenv:header> <soapenv:body> <v3:getpoifromxy> <x>41.104838</x> <y>29.033432</y> <!--1 or more repetitions:--> <category>hastane</category> <radius>2000</radius> <poicount>2</poicount> <usageid>11</usageid> </v3:getpoifromxy> </soapenv:body> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 87 / 107
</soapenv:envelope> Örnek Soap Cevap: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:getpoifromxyresponse xmlns:ns="http://v3.soap.poi.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <poilist> <address>istanbul, Sariyer, Baltalimani Mh., Metin Sabanci Baltalimani Kemik Hastaliklari</address> <city>istanbul</city> <country>turkiye</country> <county>sariyer</county> <description xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <distance>1902.31590496728</distance> <district>baltalimani Mh.</district> <latitude>29.053385</latitude> <longtitude>41.096738</longtitude> <note xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <placename>metin Sabanci Baltalimani Kemik Hastaliklari Egitim Ve Arastirma Hastanesi</placeName> <placetype>hastane</placetype> <street/> <telno>2123237075</telno> </poilist> <poilist> <address>istanbul, Sariyer, Istinye Mh., Istinye Cd.</address> <city>istanbul</city> <country>turkiye</country> <county>sariyer</county> <description xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <distance>2165.98061685496</distance> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 88 / 107
<district>istinye Mh.</district> <latitude>29.055569</latitude> <longtitude>41.114841</longtitude> <note xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <placename>istinye Devlet Hastanesi</placeName> <placetype>hastane</placetype> <street/> <telno>2122774912</telno> </poilist> <usageid>11</usageid> </return> </ns:getpoifromxyresponse> </soapenv:body> </soapenv:envelope> 5.5.2. REST Arayüzü Rest URL: http://127.0.0.1:8000/3/0/poi/poixy Örnek Rest İstek: GET http://127.0.0.1:8000/3/0/poi/poixy?category=eczane&usageid=34&y=29.033432&radius=2000&x= 41.104838&poicount=2 HTTP/1.1 Accept-Encoding: gzip,deflate Authorization: Basic c2vsaw1lqdewmdawmdawnjy6u2vsateymzq= serviceid: :1001000008 User-Agent: Jakarta Commons-HttpClient/3.1 Host: 127.0.0.1:8000 Örnek Rest Cevap: HTTP/1.1 200 OK Content-Type: application/json Content-Length: 731 Server: Jetty(6.1.25) Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 89 / 107
{ "resultcode": 0, "poilist": [ { "address": "Istanbul, Sariyer, Pinar Mh., Istinye Park AVM", "country": "Turkiye", "description": null, "city": "Istanbul", "county": "Sariyer", "district": "Pinar Mh.", "distance": 606.124295240923, "telno": null, "note": null, "placename": "Istinye Park Ecz.", "placetype": "eczane", "street": "", "latitude": 29.03215, "longtitude": 41.110209 }, { "address": "Istanbul, Sariyer, Resitpasa Mh., Tuncay Artun Cd.", "country": "Turkiye", "description": null, "city": "Istanbul", "county": "Sariyer", "district": "Resitpasa Mh.", "distance": 866.01336126486, "telno": "2122779225", "note": null, "placename": "Doga Ecz.", "placetype": "eczane", "street": "", "latitude": 29.040681, "longtitude": 41.110383 } ], Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 90 / 107
"usageid": 34, "resultdesc": "Success", "variables": null } 5.6. Rota Sorgulama İki noktanın koordinatı verilip yol tarifi alınabilir. İki noktanın koordinatının yanı sıra opsiyonel başka parametreler de girdi olarak verilmelidir ki kullanıcıya rota listesi ve koordinatlar döndürülsün. Bunun yanında başarılı veya başarısız şeklinde sonuç degeri de kullanıcıya döndürülür. Eğer istek sonucu başarısız ise kullanıcıya başarısız olma sebebini açıklayan bir sonuç döner. İstek Parametereleri Parametre Veri Tipi Zorunlu Açıklama positiononelats Double E Başlangıç noktasının enlem koordinatını belirtir positiononelongs Double E Başlangıç noktasının boylam koordinatını belirtir positiontwolats Double E Bitiş noktasının enlem koordinatını belirtir positiontwolongs Double E Bitiş noktasının boylam koordinatını belirtir route_preference String H Tercihe göre en hızlı veya en kısa yolu seçerek tarif verir. FASTEST(varsayılan) veya SHORTEST değerleri verilebilir road_ preference String H Tercihe göre otoyol veya tali yol seçilebilir. HIGHWAY(varsayılan) ve LOCAL değerleri verilebilir return_driving_directions Boolean H Yol tarifinin döndürülüp döndürülmeyeceğine karar verilir. Eğer TRUE olarka girdi verilirse tek tek rota tarif edilir. distance_unit String H Tercih edilen uzaklık birimi belirtilebilir. MILE(varsayılan), KM, METER değerlerini alabilir. time_unit String H Tercih edilen zaman birimi belirtilebilir. MINUTE(varsayılan), HOUR, SECOND değerlerini alabilir return_route_geometry Boolean H Kullanıcının koordinatları görmek isteyip istemediğine göre değişir. TRUE ise koordinatlar dönüş değerleri arasında yer alır. Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 91 / 107
usageid Long H Akışı bağlamak için gerekli olan usageid Dönüş Değerleri Parametre Veri Tipi Açıklama coordinates String Başlangıç ve bitiş noktası arasındaki her bir noktanın koordinatları döndürülür. RouteList Object Route listesi dönülür. Bu listenin içerisinde her bir tarif için şu değerler yer alır: sequence instruction distance time time double Verilen iki nokta arasını optimum alış zamanı time_unit String Zaman birimi distance double Verilen iki nokta arasının birbirine uzaklığı distance_unit String Uzaklık birimi step_count long Yol tarifinin kaç adımdan oluştuğu bilgisi ResultCode int Sorgu sonucunun başarılı veya başarısız olduğunu gösterir. ResultDesc String Sorgu sonucunu başarılı veya başarısız olduğunu gösterir. Başarılı ise SUCCESS, başarısız ise hata açıklaması yer alır. usageid Long Bu bilgi girdi oalrak verilmediyse yeni bir akış olduğu farz edilip yeni bir usageid üretilip dönülür. 5.6.1. SOAP Arayüzü Örnek Soap İstek: <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v3="http://v3.soap.poi.capabilityexposure.services.oksijen.com"> <soapenv:header> <v3:authentication v3:user="selime@1000000066" v3:password="seli1234" v3:sessionid="" v3:serviceid=":1001000008"/> </soapenv:header> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 92 / 107
<soapenv:body> <v3:getroute> <positiononelats>41.104838</positiononelats> <positiononelongs>29.033432</positiononelongs> <positiontwolats>41.104858</positiontwolats> <positiontwolongs>29.033540</positiontwolongs> <route_preference>fastest</route_preference> <road_preference>local</road_preference> <return_driving_directions>true</return_driving_directions> <distance_unit>km</distance_unit> <time_unit>minute</time_unit> <return_route_geometry>true</return_route_geometry> <usageid>22</usageid> </v3:getroute> </soapenv:body> </soapenv:envelope> Örnek Soap Cevap <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> <soapenv:body> <ns:getrouteresponse xmlns:ns="http://v3.soap.poi.capabilityexposure.services.oksijen.com"> <return> <resultcode>0</resultcode> <resultdesc>success</resultdesc> <variables xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/xmlschemainstance"/> <coordinates>29.031978161325593,41.10392844637262 29.03265288,41.10284997 29.033037,41.10272703 29.03340312,41.10275304 29.03434596,41.10321996 29.03340312,41.10275304 29.033037,41.10272703 29.03265288,41.10284997 29.03199954923409,41.1038942597481</coordinates> <distance>1.3448634033203124</distance> Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 93 / 107
<distanceunit>km</distanceunit> <routesegmentlist> <distance>0.30592495727539065</distance> <instruction>start out on İTÜ Maslak Kampüsü (Going Southeast)</instruction> <sequence>1</sequence> <time>0.6373436609903972</time> </routesegmentlist> <routesegmentlist> <distance>0.3019384765625</distance> <instruction>make a U-TURN onto İTÜ Maslak Kampüsü (Going Northwest)</instruction> <sequence>2</sequence> <time>0.6290384928385416</time> </routesegmentlist> <stepcount>2</stepcount> <time>2.8017987569173175</time> <timeunit>minute</timeunit> <usageid>22</usageid> </return> </ns:getrouteresponse> </soapenv:body> </soapenv:envelope> 5.6.2. REST Arayüzü Rest URL: http://127.0.0.1:8000/3/0/poi/route Örnek Rest İstek: GET http://127.0.0.1:8000/3/0/poi/route?positiononelongs=29.033432&return_driving_directions= true&distance_unit=km&return_route_geometry=true&route_preference=fastest&positiontwolong s=29.033540&usageid=3&positiontwolats=41.104858&positiononelats=41.104838&time_unit=minut E HTTP/1.1 Accept-Encoding: gzip,deflate Authorization: Basic c2vsaw1lqdewmdawmdawnjy6u2vsateymzq= serviceid: :1001000008 User-Agent: Jakarta Commons-HttpClient/3.1 Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 94 / 107
Host: 127.0.0.1:8000 Örnek Rest Cevap: HTTP/1.1 200 OK Content-Type: application/json Content-Length: 720 Server: Jetty(6.1.25) { "time": 2.8017987569173175, "resultcode": 0, "coordinates": "29.031978161325593,41.10392844637262 29.03265288,41.10284997 29.033037,41.10272703 29.03340312,41.10275304 29.03434596,41.10321996 29.03340312,41.10275304 29.033037,41.10272703 29.03265288,41.10284997 29.03199954923409,41.1038942597481", } "routesegmentlist": [ ], }, } { "time": 0.6373436609903972, "sequence": 1, "distance": 0.30592495727539065, "instruction": "Start out on İTÜ Maslak Kampüsü (Going Southeast)" { "time": 0.6290384928385416, "sequence": 2, "distance": 0.3019384765625, "instruction": "Make a U-TURN onto İTÜ Maslak Kampüsü (Going Northwest)" "stepcount": 2, "distance": 1.3448634033203124, "distanceunit": "km", "timeunit": "minute", "usageid": 3, "resultdesc": "Success" Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 95 / 107
6. Ek A POI Kategori Listesi İSİM acilservis akaryakitistasyonu alisverismerkezi alisveris_diger antikkentler anit apartotel aracmuayaneistasyonu aritmatesisi askerialan askeriegitimkurumu askerilojman askerisosyaltesis ayakkabi_terlik agackesmeveislemealani bankaatm bankasubesi barlar basketbol_voleybolsahasi belediyebaskanligi KATEGORİ acil servis akaryakıt istasyonu alışveriş merkezi alışveriş/diğer antik kentler anıt apart otel araç muayane istasyonu arıtma tesisi askeri alan askeri eğitim kurumu askeri lojman askeri sosyal tesis ayakkabı/terlik ağaç kesme ve işleme alanı banka atm banka şubesi bar basketbol/voleybol sahası belediye başkanlığı Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 96 / 107
belediyebaskanligivebirimleri beyazesya bilgisayar_yazilim bisikletbakim_tamirhane bisikletsaticilari bovling buzpateni bufe buyukmagazalar buyukelcilik_konsolosluk camiler cemevi cezaevi dag demiryolu_diger denizfeneri denizyolu_diger derimagazasi dernek_vakif dershane dinitesisler_diger dinlenmetesisi dispanser diyalizmerkezi belediye başkanlığı ve birimleri beyaz eşya bilgisayar/yazılım bisiklet bakım/tamirhane bisiklet satıcıları bovling buz pateni büfe büyük mağazalar büyükelçilik/konsolosluk cami cemevi cezaevi dağ demiryolu/diğer deniz feneri denizyolu/diğer deri mağazası dernek/vakıf dershane dini tesisler/diğer dinlenme tesisi dispanser diyaliz merkezi Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 97 / 107
disklinigi dondurmaci dogalgaz dogalgazidaresi durakminibus durakotobus duraktaksi dishatlarperonu eczane elektrikidaresi elektronikaletlerservis_bakim emniyet enerjiuretim_dagitim_diger egitimkurumlari_diger eglenceparklari eglenceyerleri_diger fabrika fastfood fidanlik_tohumluk finansalkurumlar_diger fuarmerkezi futbolsahasi firin_pastane gar diş kliniği dondurmacı doğalgaz doğalgaz idaresi durak (minibüs) durak (otobüs) durak (taksi) dış hatlar peronu eczane elektrik idaresi elektronik aletler servis/bakım emniyet enerji üretim, dağıtım/diğer eğitim kurumları/diğer eğlence parkları eğlence yerleri/diğer fabrika fast food fidanlık, tohumluk finansal kurumlar/diğer fuar merkezi futbol sahası fırın/pastane gar Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 98 / 107
gazino_gecekulubu gecit giyimmagazasi gise golfsahasi gidasatisnoktalari gidasatis_bufe hal halkekmekbufesi halici hamam hastane havaalani havayolufirmalari havayolu_diger hayvanpazari hayvanatbahcesi helikopterpisti hipodrom ilgicekicinoktalar ilkogretimokulu iskele iskeledenizotobusu iskeleferibot gazino/gece kulubü geçit giyim mağazası gişe golf sahası gıda satış noktaları gıda satış/büfe hal halk ekmek büfesi halıcı hamam hastane havaalanı havayolu firmaları havayolu/diğer hayvan pazarı hayvanat bahçesi helikopter pisti hipodrom ilgi çekici noktalar ilköğretim okulu iskele iskele (deniz otobüsü) iskele (feribot) Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 99 / 107
iskelesehiricihatlar itfaiye ichatlarperonu ichatlar_dishatlarperonu ismerkezivehanlar kafe kale kamping_gunubirlik kamyon_tirparki kaplica karayolu_diger kargolar katliotopark kayakmerkezi kaymakamlik kilise kitap_kirtasiye konser_operasalonu kooperatif_site kres_gunduzbakimevi kuruyemisci kultur_kongremerkezi kultureltesisler_diger kutuphane iskele (şehiriçi hatlar) itfaiye iç hatlar peronu iç hatlar/dış hatlar peronu iş merkezi ve hanlar kafe kale kamping/günübirlik kamyon/tır parkı kaplıca karayolu/diğer kargo şirketleri katlı otopark kayak merkezi kaymakamlık kilise kitap/kırtasiye konser/opera salonu kooperatif/site kreş/gündüz bakımevi kuruyemişçi kültür/kongre merkezi kültürel tesisler/diğer kütüphane Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 100 / 107
kiraathane kirmiziisikkamerasi laboratuvar_goruntuleme liman lojistik_nakliyat lojman lokanta_denizurunleri lokanta_evyemekleri lokanta_hint lokanta_italyan lokanta_kebap lokanta_kofte-izgara lokanta_kucuk lokanta_meksika lokanta_pide-lahmacun lokanta_restoran lokanta_rus lokanta_sakatat lokanta_sandwich lokanta_vejeteryan lokanta_yoreselyemekler lokanta_cin-japon lpgistasyonu madencikarmaveislemealani kıraathane kırmızı işık kamerası laboratuvar/görüntüleme liman lojistik/nakliyat lojman lokanta/deniz ürünleri lokanta/ev yemekleri lokanta/hint lokanta/italyan lokanta/kebap lokanta/köfte-izgara lokanta/küçük lokanta/meksika lokanta/pide-lahmacun lokanta/restoran lokanta/rus lokanta/sakatat lokanta/sandwich lokanta/vejeteryan lokanta/yöresel yemekler lokanta/çin-japon lpg istasyonu maden çıkarma ve işleme alanı Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 101 / 107
mahkeme manzaraliyerler magara medikal medya mesirealani meslekodasi metroistasyonu mevki mezarlikhiristiyan mezarlikmusevi mezarlikmusluman millipark misafirhane_egitimvedinlenmetesisleri mobilyaci motosikletbakim_tamirhane motosikletsaticilari muayenehane muhtarlik muzeler noter optik ormanlikalanlar ortaogretimokulu mahkeme manzaralı yerler mağara medikal medya mesire alanı meslek odası metro istasyonu mevki mezarlık (hıristiyan) mezarlık (musevi) mezarlık (müslüman) milli park misafirhane, eğitim ve dinlenme tesisleri mobilyacı motosiklet bakım/tamirhane motosiklet satıcıları muayenehane muhtarlık müze noter optik ormanlık alanlar ortaöğretim okulu Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 102 / 107
otel otobakim_tamirhane otokiralama otokiralamaparkalani otokurtarma otolastik otosaticilari otoyetkilisaticilari otoyetkiliservisleri otoyikama otobusfirmalari otogar otoparkacikgenel otoparkacikozel otoparkkapali outlet oyuncakci pansiyon pazaralani pizza plaj poliklinik poliskarakolu postane otel oto bakım/tamirhane oto kiralama oto kiralama park alanı oto kurtarma oto lastik oto satıcıları oto yetkili satıcıları oto yetkili servisleri oto yıkama otobüs firmaları otogar otopark (açık) genel otopark (açık) özel otopark (kapalı) outlet oyuncakçı pansiyon pazar alanı pizza plaj poliklinik poliskarakolu postane Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 103 / 107
radar resmikurum resmikurum_diger sanayisitesi sanayitesisi sanayiveuretimalanlari_diger sarayvekasirlar saglikkurumlari_diger sendika sera serbestbolge sergisalonu simitci sinagog sinema sitalani siviltoplumorgutleri_diger siyasiparti sosyalamaclikurumlar_diger sosyalyardimkurumlari spormerkezi sporsalonu sportesisi sportesisleri_diger radar resmi kurum resmi kurum/diğer sanayi sitesi sanayi tesisi sanayi ve üretim alanları/diğer saray ve kasırlar sağlık kurumları/diğer sendika sera serbest bölge sergi salonu simitçi sinagog sinema sit alanı sivil toplum örgütleri/diğer siyasi parti sosyal amaçlı kurumlar/diğer sosyal yardım kurumları spor merkezi spor salonu spor tesisi spor tesisleri/diğer Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 104 / 107
stadyum sudeposu suidaresi suparki su_kanalizasyon_cop_diger sucu surucukursu sinirkapisi tarihieser tarihiveturistiktesisler_diger tarimsaluretimalanlari_diger tatilkoyu tekelbayi teleferik telekom telekomunikasyon telekomunikasyon_diger teniskortu tersane ticaretalanlari_diger tiyatrolar toptanticaretalani trafikisiklari trafo stadyum su deposu su idaresi su parkı su, kanalizasyon, çöp/diğer sucu sürücü kursu sınır kapısı tarihi eser tarihi ve turistik tesisler/diğer tarımsal üretim alanları/diğer tatil köyü tekel bayi teleferik telekom telekomünikasyon telekomünikasyon/diğer tenis kortu tersane ticaret alanları/diğer tiyatro toptan ticaret alanı trafik işıkları trafo Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 105 / 107
tramvayistasyonu trenistasyonu_sehirici trenistasyonu_sehirlerarasi turizmdanisma turizmfirmalari turkuevi umumituvalet vergidairesi vericiistasyonu veteriner yapimarketleri yarispisti yatlimani yedekparcaci yeme-icmeyerleri_diger yesilalan yurtlar yuksekokul_akademi yuzmehavuzu zabita zincirmarketler carsivepasajlar caybahcesi ciftlik tramvay istasyonu tren istasyonu/şehiriçi tren istasyonu/şehirlerarası turizm danışma turizm firmaları türkü evi umumi tuvalet vergi dairesi verici istasyonu veteriner yapı marketleri yarış pisti yat limanı yedek parçacı yeme-içme yerleri/diğer yeşil alan yurt yüksek okul/akademi yüzme havuzu zabıta zincir marketler çarşı ve pasajlar çay bahçesi çiftlik Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 106 / 107
cicekcilik cocukbahcesi cocukgiyimmagazasi onemlinoktalar_diger universite universite_bolum sarkuteri sirketler vodafone Telekomünikasyon KizilayMobil KizilaySabit poliskarakolu çiçekçilik çocuk bahçesi çocuk giyim mağazası önemli noktalar/diğer üniversite üniversite/bölüm şarküteri şirketler vodafone Telekomünikasyon KizilayMobil KizilaySabit karakol Sürüm: 2.16 Tarih: 25/12/2012 Kod: CAPABILITY_EXPOSURE_PLATFORM_API Sayfa: 107 / 107