GET | /filters | Gets the list of available filters |
---|
import Foundation
import ServiceStack
public class FilterRequest : BasicResourceLibraryRequest
{
required public init(){ super.init() }
required public init(from decoder: Decoder) throws {
try super.init(from: decoder)
}
public override func encode(to encoder: Encoder) throws {
try super.encode(to: encoder)
}
}
public class BasicResourceLibraryRequest : Codable
{
public var resourceLibraryMemberId:Int?
required public init(){}
}
public class FilterResponse : Codable
{
public var filters:[Filter] = []
required public init(){}
}
public class Filter : Codable
{
public var id:String?
public var name:String?
public var category:String?
public var bitwiseId:UInt64?
required public init(){}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /filters HTTP/1.1 Host: resourcelibrary.api.ashcompanies.com Accept: text/csv
HTTP/1.1 200 OK Content-Type: text/csv Content-Length: length {"filters":null}