You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The interactive portion of these docs provides a mock API server - it's possible to send calls over to it to ensure you're seeing the correct responses in return.
To do this, choose an endpoint / action, eg:
You'll see a test URL near the top on the right (https://private-xxxxx-codeclubworldapiv2.apiary-mock.com/clubs). You can use this URL for mocking calls (ie. replace the value of CCW_API_URL in the theme's inc/country-config.php with that Apiary URL, minus the /club portion). Firing off calls to the mock server will return responses such as the following on club creation:
HTTP/1.1 201 Created
Server: Cowboy
Connection: keep-alive
X-Apiary-Ratelimit-Limit: 120
X-Apiary-Ratelimit-Remaining: 119
Content-Type: application/json
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: OPTIONS,GET,HEAD,POST,PUT,DELETE,TRACE,CONNECT
Access-Control-Max-Age: 10
X-Apiary-Transaction-Id: 58c14a56d6584c1900186e83
Content-Length: 1184
Date: Thu, 09 Mar 2017 12:28:07 GMT
Via: 1.1 vegur
{ club json here ... }
It'll display errors if the request is malformed.
You can also use Apiary to generate example API calls in many languages/formats: