Finland DNA MSISDN Forwarding
MSISDN Forwarding Finland DNA
MSISDN Forwarding is a process that enables you to capture a phone number (the MSISDN) for billing the end user via an approved flow between the mobile networks (the MNOs), MessageCloud’s platform, and your server.
Now available in Finland for the first time, MSISDN Forwarding enables simpler premium rate services via MessageCloud's APIs, targeting 4.8 million mobile subscribers.
Please note that each of the MNOs in Finland implement MSISDN Forwarding in quite different ways, so you will need to ensure you take into account the differences. Our APIs will help you to integrate both kinds of implementation.
DNA
DNA is similar to Elisa/Saunalahti in that there are three main steps to take: creating a session, redirect the end user and retrieving the MSISDN. The big difference, however, is the method you need to use to redirect the end user. It is necessary to have the end user visit the URL directly rather than perform an HTTP 302. The latter method will not work on this network.
Charging an end user on this network can be made possible by using our DNA Direct Operator Billing API.
Transaction flow
Create a session
To create a session you should perform an HTTP GET request to:
https://client.txtnation.com/finland/dna_session.php
The API expects the following parameters to be sent:
Variable Name | Example | Description | Restrictions |
---|---|---|---|
cc |
joebloggs | Your company name in our platform | This must be between 2 and 30 alphanumeric characters |
ekey |
88C3CF364123A25BBAB687D4FE8EC628 | Your ekey in our platform | This will be provided on set up and is available in my.messagecloud.com. |
category |
3 | The type of content that is being accessed by the end user | 1 = General services, 2 = Consulting and ordering services, 3 = Entertainment services, 4 = Adult services |
return_url |
http://my.server.com/payment | The URL to which the end user will be sent once the MSISDN is obtained | n/a |
A successful call to this API will return JSON in the format:
{ "status": "ok", "ref_id": "55cdbc9279828" }
The ref_id
returned from this request is your session ID. We use this to ensure that the result of the MSISDN discovery is available to you at the end of the process. If the request is unsuccessful you will receive status: "error"
in the response. An example of this is shown below:
{ "status": "error", "error_code": 1, "error_message": "Missing parameter: cc" }
Including the HTTP response headers, the full response may look like this:
HTTP/1.1 400 Bad Request X-Served-By: Eos.txtnation.UK Content-type: application/json; charset=utf-8 Transfer-Encoding: chunked Date: Fri, 03 Jun 2016 14:43:34 GMT Server: txtNation HTTP Server {"status":"error","error_code":1,"error_message":"Missing parameter: cc"}
A full list of error codes are displayed below for your reference:
Error code | HTTP code | Description |
---|---|---|
1 | 400 | There was a missing required parameter in the request. Further details about which parameter will be supplied in the error message. |
2 | 400 | One or more of the parameters sent was in an unexpected format, for example, ekey was not 32 characters in length. |
3 | 403 | Could not authenticate the company and ekey values you sent. |
4 | 500 | There was an internal error. If the problem persists please contact MessageCloud Support. |
Redirect the user
Unlike Elisa/Saunalahti you must make the end user visit the http://client.txtnation.com/finland/dna_redirect.php?ref_id=55cdbc9279828 URL, using the ref_id returned to you after the first API call to dna_session
. HTTP 302 redirects do not work on DNA.
Once the user has visited this URL, and the MSISDN has been discovered, the end user will be redirected back to the return_url
you provided during the initial call to dna_session
.
Requesting the MSISDN
Once the user has returned to your return_url
, you can call the retrieval API to obtain the MSISDN. The API is hosted at:
https://client.txtnation.com/finland/dna_get_msisdn.php
The API expects the following parameters to be sent:
Variable Name | Example | Description | Restrictions |
---|---|---|---|
cc |
joebloggs | Your company name in our platform | This must be between 2 and 30 alphanumeric characters |
ekey |
88C3CF364123A25BBAB687D4FE8EC628 | Your ekey in our platform | This will be provided on set up and is available in my.messagecloud.com. |
ref_id |
5243bc6ade5eedcdee | The session ID returned during dna_session |
n/a |
ip |
86.214.255.123 | The IP address of the end user who is accessing your page | n/a |
A successful call to this API will return JSON in the format:
{ "status": "ok", "ref_id": "55cdbc9279828", "msisdn": "358468253836", "transaction_id": "I6543234567", "ip": "86.214.255.123", }
If the request is unsuccessful you will receive status: "error" in the response. An example of this is shown below:
{ "status": "error", "error_code": 1, "error_message": "Missing parameter: cc" }
Including the HTTP response headers, the full response may look like this:
HTTP/1.1 400 Bad Request X-Served-By: Eos.txtnation.UK Content-type: application/json; charset=utf-8 Transfer-Encoding: chunked Date: Fri, 03 Jun 2016 14:48:34 GMT Server: txtNation HTTP Server {"status":"error","error_code":1,"error_message":"Missing parameter: cc"}
A full list of error codes are displayed below for your reference:
Error code | HTTP code | Description |
---|---|---|
1 | 400 | There was a missing required parameter in the request. Further details about which parameter will be supplied in the error message. |
2 | 400 | One or more of the parameters sent was in an unexpected format, for example, ekey was not 32 characters in length. |
3 | 403 | Could not authenticate the company and ekey values you sent. |
4 | 503 | There was an internal error. If the problem persists please contact MessageCloud Support. |
5 | 400 | Could not find the transaction_id in our records. |
6 | 400 | No MSISDN was returned by DNA. |