Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

BlackBerry Push Development

Reply
Contributor
Posts: 15
Registered: ‎09-14-2011
My Device: blackberry 6
My Carrier: verizon

Invalid or missing attribute address-value

I'm getting an error when I try to Push a message to the BB Push server.  Any help would be appreciated.  Below is from my server log.

 

27 Feb 2013 11:11:17,535 DEBUG MessagingThread - Push Id: 7467968197814124549 type: BlackberryPushService-HttpConnectionManager:55 - Executing request - https://cp3284.pushapi.eval.blackberry.com/mss/PD_pushRequest


27 Feb 2013 11:11:17,805 DEBUG MessagingThread - Push Id: 7467968197814124549 type: BlackberryPushService-BlackberryPushService:55 - Server returned the response - <?xml version="1.0"?>
<!DOCTYPE pap PUBLIC "-//WAPFORUM//DTD PAP 2.1//EN" "http://www.openmobilealliance.org/tech/DTD/pap_2.1.dtd"><pap><badmessage-response code="2000" desc="Invalid or missing attribute address-value" bad-message-fragment="Invalid or missing attribute address-value"/></pap>


27 Feb 2013 11:11:17,805 ERROR MessagingThread - Push Id: 7467968197814124549 type: BlackberryPushService-BlackberryPushService:27 - Server reported the request format to be incorrect.

Retired
Posts: 311
Registered: ‎08-08-2012
My Device: BlackBerry Z10
My Carrier: Rogers

Re: Invalid or missing attribute address-value

Hi,

 

The PAP spec for push requires an address tag and address-value attribute.

It looks like this:

<address address-value="some_pin"/>

 

You need one for each address/device you push to.

 

It doesn't look like you're using the Push Service SDK for implementing your Push Initiator, are you?

 

Matt

 

Retired
Posts: 76
Registered: ‎08-08-2012
My Device: BlackBerry Z10
My Carrier: Rogers

Re: Invalid or missing attribute address-value

Can you provide the XML you are sending to the Push Service? (please remove or hide any sensitive data)

 

 

As Matthew mentioned the value of the address element attribute should be a device PIN (8 characters)

Contributor
Posts: 15
Registered: ‎09-14-2011
My Device: blackberry 6
My Carrier: verizon

Re: Invalid or missing attribute address-value

Thanks Matt,

 

When I register my BB device with BB Push it returns the device ID.  I now see I need to send PIN to the BB Push server.

Contributor
Posts: 15
Registered: ‎09-14-2011
My Device: blackberry 6
My Carrier: verizon

Re: Invalid or missing attribute address-value

[ Edited ]

Here is the code I'm using when I register my BB device.

 

               local pushregconfig = {appid="some_app_id",

                                                           port=some_port,

                                                           bpasurl="http://cpxxxx.pushapi.eval.blackberry.com",

                                                           appicon="jeeplogo57x57.png",

                                                           starappicon="jeeplogo57x57.png",

                                                           statusbaricon="jeeplogo57x57.png"}

               push.register(pushregconfig)

Retired
Posts: 311
Registered: ‎08-08-2012
My Device: BlackBerry Z10
My Carrier: Rogers

Re: Invalid or missing attribute address-value

Sorry, this code is from your BB device itself?  Or, are you talking about server-side (Push Initiator) code?

Contributor
Posts: 15
Registered: ‎09-14-2011
My Device: blackberry 6
My Carrier: verizon

Re: Invalid or missing attribute address-value

Parameters sent to blackberry service provider while registering blackberry device

Retired
Posts: 311
Registered: ‎08-08-2012
My Device: BlackBerry Z10
My Carrier: Rogers

Re: Invalid or missing attribute address-value

Dumb question perhaps, but what langauge is your code written in? :smileyhappy:

Contributor
Posts: 15
Registered: ‎09-14-2011
My Device: blackberry 6
My Carrier: verizon

Re: Invalid or missing attribute address-value

LUA is the language the app is written in.

 

Here are the parameters we are pasing to the BB Push server after the device is registered.

 

<messageRequest appId='~_APP_ID_~'>
<messages>
<message refId='~_REFID_~' type='PUSH' msgOnFailure='true'>
<subscribers>
<subscriber ksid='~_KSID_~' />
</subscribers>
<platformSpecificProps>
<iphone>
<badge>~_BADGE_MESSAGE_DATA_~</badge>
<sound>DEFAULT</sound>
</iphone>
</platformSpecificProps>
<content>
<mimeType>text/plain</mimeType>
<data>~_MESSAGE_DATA_~</data>
</content>
</message>
</messages>
</messageRequest>

Retired
Posts: 76
Registered: ‎08-08-2012
My Device: BlackBerry Z10
My Carrier: Rogers

Re: Invalid or missing attribute address-value

I am not sure if you saw my reply but could you cpature the actual XML request you are sending to the BlackBerry Push Service (strip out any confidential information) so we can validate it? The issue seems to be with the way the XML is being constructed or what you've put into the XML specifically.