| GET | /hobbies/{brand}/{posCode} | Get customer hobbies |
|---|
import Foundation
import ServiceStack
public class GetHobbies : Codable
{
/**
* Brand
*/
// @ApiMember(Description="Brand", IsRequired=true)
public var brand:String
/**
* POS Legacy
*/
// @ApiMember(Description="POS Legacy", IsRequired=true)
public var posCode:String
required public init(){}
}
public class GetHobbiesResponse : List<Hobby>
{
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 Hobby : Codable
{
/**
* Hobby description
*/
// @ApiMember(Description="Hobby description", IsRequired=true)
public var hobby:String
/**
* SAP Hobby ID, e.g. 'ART'
*/
// @ApiMember(Description="SAP Hobby ID, e.g. 'ART'", IsRequired=true)
public var sapHobbyId:String
/**
* Hobby description translation
*/
// @ApiMember(Description="Hobby description translation")
public var translation:String
required public init(){}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /hobbies/{brand}/{posCode} HTTP/1.1
Host: dev-api-booster.richemont.com
Accept: text/jsonl
HTTP/1.1 200 OK Content-Type: text/jsonl Content-Length: length []