0

New to php (used C and VB years ago) Using a Temboo API for Ebay, I'm attempting to retrieve messages from our eBay account. Although the API says it will return a JSON string, when executing it returns an object. Using var_dump(get_defined_vars($getMemberMessagesResults)); returns this relevant information:

'getMemberMessagesResults' => 
    object(eBay_Trading_GetMemberMessages_Results)[7]
      protected 'outputArray' => 
        array (size=1)
          'Response' => string '{"@xmlns":"urn:ebay:apis:eBLBaseComponents","Timestamp":"2021-07-29T21:52:49.047Z","Ack":"Warning","...
      protected 'lowercaseKeyMap' => 
        array (size=1)
          'response' => string 'Response' (length=8)

I am trying to extract the information 'Response'=> string('xlmns":"urn:ebay:apis"... information so that I can then process to put in a database. But, I cannot figure out how to reference this information to extract it. I've tried lots of references but so far I've been stumped. I realize the information is probably there somewhere but being new to PHP I'm feeling stumped. Thanks in advance for your assistance.

AbraCadaver
  • 78,200
  • 7
  • 66
  • 87
  • The property is marked "protected", meaning that it is internal to the class and can't be accessed directly from the outside; see https://www.php.net/manual/en/language.oop5.visibility.php What methods the library provides for working with that data is not a question of general PHP knowledge but the documentation for that specific library, and what you need to look for friends what you're actually trying to achieve, so the question isn't really answerable as you've currently presented it. – IMSoP Jul 29 '21 at 22:44
  • Thanks. You actually answered the question. – Jack Phillips Jul 30 '21 at 00:52

0 Answers0