Guest User

Untitled

a guest
Sep 23rd, 2018
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.57 KB | None | 0 0
  1. swagger: '2.0'
  2. info:
  3. version: 1.0.0
  4. title: Documentation API
  5. paths:
  6. /agent:
  7. post:
  8. consumes:
  9. - multipart/form-data
  10. produces:
  11. - text/html
  12. parameters:
  13. - in: query
  14. name: method
  15. description: name of method to access
  16. required: true
  17. type: string
  18. - in: body
  19. name: param
  20. description: parameter to send
  21. required: true
  22. schema:
  23. $ref: "#/definitions/Param"
  24. responses:
  25. 201:
  26. description: item created
  27. 400:
  28. description: invalid input, object invalid
  29. 409:
  30. description: an existing item already exists
  31. definitions:
  32. Param: # <----------
  33. type: object
  34. required:
  35. - username
  36. - password
  37. - imsi
  38. - imei
  39. - deviceId
  40. properties:
  41. username:
  42. type: string
  43. password:
  44. type: string
  45. imsi:
  46. type: string
  47. imei:
  48. type: string
  49. deviceId:
  50. type: string
  51. host: 'localhost'
  52. basePath: /v1/api
  53. schemes:
  54. - https
  55.  
  56. curl -X POST "https://localhost/v1/api/agent?method=login" -H "accept: text/html" -H "content-type: multipart/form-data" -F {"username":"1234567890","password":"1234567890","imsi":"310260000000000","imei":"000000000000000","deviceId":"9ca9b02b237a6dae"}
  57.  
  58. curl -X POST "https://localhost/v1/api/agent?method=login" -H "accept: text/html" -H "content-type: multipart/form-data" -F 'param={"username":"1234567890","password":"1234567890","imsi":"310260000000000","imei":"000000000000000","deviceId":"9ca9b02b237a6dae"}'
Add Comment
Please, Sign In to add comment