B4J Question What is the best soluton to post the xml-code

schimanski

Well-Known Member
Licensed User
Longtime User
Hello and happy new year!

After spending much hours, I'm now able to push an blackberry-device with the following code. I use the google-chrome poster add-on with the following URL, header und body. What would be the best solution, to post the xml-code from my jserver?

Thanks for help...

URL:
B4X:
https://cpXXXX.pushapi.eval.blackberry.com/mss/PD_pushRequest

Headers:
B4X:
Content-Type:multipart/related; boundary=PMasdfglkjhqwert;type=application/xml
Authorization:Basic xxxXXXXxxxxXXXXXsN283MzpOQWZOVnJONg==

Content-Body:
B4X:
--PMasdfglkjhqwert
Content-Type: application/xml; charset=UTF-8

<?xml version="1.0"?>
<!DOCTYPE pap PUBLIC "-//WAPFORUM//DTD PAP 2.1//EN" "http://www.openmobilealliance.org/tech/DTD/pap_2.1.dtd">
<pap>
  <push-message push-id="999999999"  source-reference="XXXX-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"  deliver-before-timestamp="2020-12-31T23:59:59Z">    <address address-value="2X192XXX"/>
    <quality-of-service delivery-method="confirmed"/>
  </push-message>
</pap>
--PMasdfglkjhqwert

{

     "key1":"value1",

      "key2":"value2",

     "key3":"value3",

      "key4":"value4"

}

--PMasdfglkjhqwert–-
 

schimanski

Well-Known Member
Licensed User
Longtime User
:DYes, it works!!! You are a genius!!!! Thank you very much. That was one of the things, that made me headache....
 
Upvote 0

schimanski

Well-Known Member
Licensed User
Longtime User
I have deleted the screenshots and the projects with my own credentials. In the next days, I will write it down in a tutorial "creating push-enabled apps on blackberry".
 
Upvote 0
Top