2

I have to use an API for my android app without any documentation. Before in my work I always had documentation, so this is a new situation for me. Backend developers said their api supports option requests. How to send option request? Using browser or what? And how to find out what I should put in POST requests' bodies? Thanks for your help in advance!

EricAll
  • 33
  • 1
  • 4
  • 3
    Tell your boss to fire the backend developers and replace them with developers who will write documentation. – CommonsWare Sep 05 '17 at 14:42
  • Yeah, seriously ^ there's no way you're going figure this out without, like, [fuzzing](https://en.wikipedia.org/wiki/Fuzzing) the API. – msanford Sep 05 '17 at 17:28

1 Answers1

5

You can issue an OPTIONS request (which is an HTTP method like GET or POST) like so with, say, curl:

curl -X OPTIONS http://example.org -i

or Postman.

However, OPTIONS is designed only to reply with the methods a particular endpoint accepts: I can do GET and POST. It would be rather irregular for it to respond with an expected data structure, but nothing is impossible.

msanford
  • 11,803
  • 11
  • 66
  • 93