• Resolved roel.martens

    (@roelmartens)


    Hello,

    I want to show the follwing at my website. How should the code look like that I put on my WP page?

    Webservice
    accessavailability:
    https://portal.pocos.nl:8443/accessavailability

    Parameters
    payload JSONobject:
    {
    “postalCode”: {
    “value”: “5653LC”
    },
    “number”: {
    “value”: “9”
    },
    “numberAdditional”:
    {
    “value”:”c”
    }
    }
    The parameter numberAdditional is optional.

    Results
    Exampleresults with results:
    {
    “address”:
    {
    “postalCode”: “5653LC”,
    “number”: “9”,
    “numberAddition”: “c”,
    “street”: “CROY”,
    “residence”: “EINDHOVEN”,
    “latitude”: “51.431719596652”,
    “longitude”: “5.493932117236”
    },
    “availability”:
    [
    {
    “supplier”: “KPN WBA”,
    “portfolio”: “BITSTREAM”,
    “technology”: “ADSL2+_ISDN”,
    “product”: “12.0 Mbps / 1.0 Mbps”
    },
    {
    “supplier”: “KPN WEAS”,
    “portfolio”: “WEAS”,
    “technology”: “Copper”,
    “product”: “20 Mbps”
    },
    },
    “supplier”: “TELE2”,
    “portfolio”: “Tele2”,
    “technology”: “Extended Ethernet 4 pair”,
    “product”: “20.0 Mbps, afstand 1055m”
    },
    },
    “supplier”: “Eurofiber”,
    “portfolio”: “Fiber”,
    “technology”: “Fiber”,
    “product”: “1000 Mbps, afstand 62m”
    },
    },
    “supplier”: “Overige”,
    “portfolio”: “Glasvezel Eindhoven”,
    “technology”: “Fiber”,
    “product”: “1000 Mbps”
    }
    ],
    unavailableChecks: [
    “KPN WEAS”,
    “KPN WBA”
    ],
    “exitCode”: 0
    }
    Exampleresults without results:
    {
    “availability”: [],
    “exitCode”: 1
    }
    Exampleresults with faultresults:
    {
    “exitCode”: 2,
    “message”: “An unexpected error occurred. Notification sent to ACME servicedesk (servicedesk@acme)}

    https://ww.wp.xz.cn/plugins/json-content-importer/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author berkux

    (@berkux)

    Hi roel.martens,

    to understand this:
    You’re asking (the yet unavailable)
    https://portal.pocos.nl:8443/accessavailability
    by posting a JSON like “Parameters payload JSONobject:”.

    The answer is “Exampleresults with results:” or “Exampleresults without results:” or “Exampleresults with faultresults:”.

    Did I get that right?

    If so:
    Posting a JSON to API by GET (not POST): The PRO-Version of the Plugin can handle GET-requests. Such API-Communication I did with several individual projects as this can get somecome special. How you must deliver the payload?

    Plugin Author berkux

    (@berkux)

    “resolved” due to inactivity

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

The topic ‘simple webservice?’ is closed to new replies.