Skip to content

Instantly share code, notes, and snippets.

@cdsap
Created April 18, 2018 13:08
Show Gist options
  • Save cdsap/98f616d5cd5026414b223dc0b99b35b6 to your computer and use it in GitHub Desktop.
Save cdsap/98f616d5cd5026414b223dc0b99b35b6 to your computer and use it in GitHub Desktop.
Api Endpoints
@Api(name = "api", version = "v1")
class ApiServer {
@ApiMethod(name = "sync",
httpMethod = ApiMethod.HttpMethod.GET,
path = "sync/{pair}")
fun sync(@Named("pair") id: String) = syncService.sync(id)
@ApiMethod(name = "trades",
httpMethod = ApiMethod.HttpMethod.GET,
path = "trades/{pair}")
fun getTrades(@Named("pair") id: String) = getTradesService.getTrades(id)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment