• Resolved DocBray

    (@docbray)


    Hello!

    I am attempting to display some basic data from my live streaming stats API. The URL for the JSON is: https://api.wmspanel.com/v1/realtime_data?client_id=3d152cd5-8ea7-41bd-9083-ef50a1c3f6fd&api_key=3aed7c177f7648775ef07230ac2a4b7a&data_slice=569fbc8f7d5c00a2130000aa

    The JSON it displays is:
    {"status":"Ok","realtime_data":{"connected":0,"bandwidth":0,"geo":[]}}

    I’ve tried a few things since installing the plugin based on examples and some info from forum posts, but don’t know what is stopping info from displaying.

    I get a “problems with JSON-structure: check basenode-param” error no matter what, and sometimes it complains about “neither object nor array? not implemented yet” as well.

    The shortcode that I am currently using that “seems” like it should work is:

    [jsoncontentimporter url=”https://api.wmspanel.com/v1/realtime_data?client_id=3d152cd5-8ea7-41bd-9083-ef50a1c3f6fd&api_key=3aed7c177f7648775ef07230ac2a4b7a&data_slice=569fbc8f7d5c00a2130000aa″ numberofdisplayeditems=”-1″ method=rawget basenode=”realtime_data”]Users={connected}[/jsoncontentimporter]

    And the page I am using it on is: https://supernerdland.com/jsonapi-test/

    Any help is absolutely appreciated, as I don’t know if I am just being a noob and not implementing this correctly or if I need the PRO version because of how the JSON is output.

    I do know the plugin itself works! I tried the http://www.swissfunddata.ch example from your website and it worked just fine lol

    Thanks for your time!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter DocBray

    (@docbray)

    Small update:

    Still not working, but I did fix the ” usage throughout, and put ” around rawget (I’ve also tried just not including method=).

    Still no go on getting data to display sadly.

    Plugin Author berkux

    (@berkux)

    Hi DocBray,

    yet
    https://api.wmspanel.com/v1/realtime_data?client_id=3d152cd5-8ea7-41bd-9083-ef50a1c3f6fd&api_key=3aed7c177f7648775ef07230ac2a4b7a&data_slice=569fbc8f7d5c00a2130000aa
    is not giving JSON. Mybe something expired since the day before yesterday.

    Try this (remove all quotation marks, method is a PRO-feature, numberofdisplayeditems=-1 is default):

    [jsoncontentimporter url=https://api.wmspanel.com/v1/realtime_data?client_id=3d152cd5-8ea7-41bd-9083-ef50a1c3f6fd&api_key=3aed7c177f7648775ef07230ac2a4b7a&data_slice=569fbc8f7d5c00a2130000aa basenode=realtime_data]Users={connected}[/jsoncontentimporter]

    Thread Starter DocBray

    (@docbray)

    Thank you for the reply!

    I actually believe the issue is an access issue to the API that outputs the JSON. The reason the link doesn’t work is because I have to whitelist IPs that want to access it. Which I have for my computer and the server the site is hosted on.

    But when I was troubleshooting, and testing out some basic PHP echo functions, it still wouldn’t work. Even though I could echo the contents of http://twww.swissfunddata.ch/sfdpub/fragment/current/16701, I couldn’t echo the API JSON URL.

    I am in contact with the folks who handle the API stuff to get this solved farther, as I do believe that is the core issue, and not the plug-in at all 🙂

    Thanks again for the time!

    Plugin Author berkux

    (@berkux)

    Hi,

    sometimes API need some basic header data like useragent.
    You’re on the right track to check what the API needs.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Issue dispaying some basic JSON data (Noob help lol)’ is closed to new replies.