Skip to content
This repository has been archived by the owner on May 30, 2022. It is now read-only.

Latest commit

 

History

History
42 lines (31 loc) · 1.21 KB

API.md

File metadata and controls

42 lines (31 loc) · 1.21 KB

cm_server API

/ GET

Return index.html


/calculate POST

Header

Key Value
Content-Type application/json

Body

Key Type Description
src_filename string filename of source_data, file must be in same dir of cm_server

For other params, see Readme

NOTE: replace '-' to '_' in keys' name

Response

Code Body_key Type Description
200 result_num int number of combinations got from calculator
- output_file string output file path
403 reason string IOError: source_data may not exist or output_file is not writable
500 reason string InternalError: traceback info

/status GET

Response

Code Body_key Type Description
200 status string value is "running"
- progress(Optional) float calculating precent, between 0 to 1
- current(Optional) int calculated combinations
- total(Optional) int total combinations