forked from stanfy/helium
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Some of API specs could have parameters, encoded in the URI. And Helium is not able to produce correct output in the Swift which allows to use such parameters. For instance, for the request:
get "/service_config" spec {
name "Available services"
description "Returns available services for a specified affiliate."
parameters {
where 'string'
max_results 'int32'
}
response "AffiliateServiceListResponse"
httpHeaders header('Cache-Control', 'no-cache')
}
it produces output like this:
public func getServiceGroup(where: String, maxResults: Int) -> SignalProducer<AffiliateServiceGroupListResponse, APIResponseError<NSError>> {
let url = URL(string:baseURL.absoluteString + "/service_group")!
In this output parameters aren't applicable at all, it must be something like this:
let url = URL(string:baseURL.absoluteString + "/service_group?where=" + whereClause + "&max_results=" + String(maxResults))!
Metadata
Metadata
Assignees
Labels
No labels