GET | /sales/wallet/wallettokencreate | Creates a Wallet Token for a user |
---|
namespace ClubReady.Core.Api.Models
open System
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations
[<AllowNullLiteral>]
type ApiResponseBase() =
member val Success:Boolean = new Boolean() with get,set
member val Message:String = null with get,set
[<AllowNullLiteral>]
type WalletTokenCreateResponseDto() =
inherit ApiResponseBase()
member val WalletToken:String = null with get,set
member val WalletOrigin:String = null with get,set
member val WalletUrl:String = null with get,set
[<AllowNullLiteral>]
type WalletTokenCreateResponse() =
inherit WalletTokenCreateResponseDto()
member val Success:Boolean = new Boolean() with get,set
member val Message:String = null with get,set
member val WalletToken:String = null with get,set
member val WalletOrigin:String = null with get,set
member val WalletUrl:String = null with get,set
[<AllowNullLiteral>]
type ApiDtoBase() =
member val ApiKey:String = null with get,set
member val StoreId:Nullable<Int32> = new Nullable<Int32>() with get,set
member val ChainId:Nullable<Int32> = new Nullable<Int32>() with get,set
[<DataContract>]
type OwnerType =
| Unknown = 0
| User = 1
| ConvUser = 2
| TempCart = 3
| TempAgmt = 4
| Store = 5
| Chain = 6
| Division = 7
| District = 8
| AdminType = 9
| TempStUser = 10
| VaultApi = 11
| Company = 12
| BackOfficeStore = 13
| OrgUser = 14
| CartItem = 15
| Testing = 99
| System = 100
| Error = -1
type WalletPage =
| Uninitialized = 0
| Manage = 1
| Add = 2
| AddCard = 3
| AddBank = 4
| AddMini = 5
| AddCardMini = 6
| AddBankMini = 7
[<AllowNullLiteral>]
type WalletTokenCreateRequestDto() =
inherit ApiDtoBase()
member val OwnerId:Int32 = new Int32() with get,set
member val OwnerType:OwnerType = new OwnerType() with get,set
member val CreatorId:Int32 = new Int32() with get,set
member val Page:WalletPage = new WalletPage() with get,set
member val Theme:String = null with get,set
member val AllowDeleteProfile:Nullable<Boolean> = new Nullable<Boolean>() with get,set
member val AllowDisableProfile:Nullable<Boolean> = new Nullable<Boolean>() with get,set
type RestrictedResourceType =
| Store = 0
| Chain = 1
| User = 2
| Undefined = 3
[<AllowNullLiteral>]
type WalletTokenCreateEndpoint() =
inherit WalletTokenCreateRequestDto()
///<summary>
///Api Key - grants access to resources
///</summary>
[<ApiMember(DataType="string", Description="Api Key - grants access to resources", IsRequired=true, Name="ApiKey", ParameterType="query")>]
member val ApiKey:String = null with get,set
///<summary>
///ID # of the owner to create the URL for
///</summary>
[<ApiMember(DataType="integer", Description="ID # of the owner to create the URL for", IsRequired=true, Name="OwnerId", ParameterType="query")>]
member val OwnerId:Int32 = new Int32() with get,set
///<summary>
///Type of owner to create the URL for
///</summary>
[<ApiMember(Description="Type of owner to create the URL for", IsRequired=true, Name="OwnerType", ParameterType="query")>]
member val OwnerType:OwnerType = new OwnerType() with get,set
///<summary>
///Person creating the profile. Can be same as OwnerId.
///</summary>
[<ApiMember(Description="Person creating the profile. Can be same as OwnerId.", IsRequired=true, Name="CreatorId", ParameterType="query")>]
member val CreatorId:Int32 = new Int32() with get,set
///<summary>
///Page to display when calling the Payment Profile iFrame
///</summary>
[<ApiMember(Description="Page to display when calling the Payment Profile iFrame", IsRequired=true, Name="Page", ParameterType="query")>]
member val Page:WalletPage = new WalletPage() with get,set
///<summary>
///CSS Theme
///</summary>
[<ApiMember(Description="CSS Theme", ParameterType="query")>]
member val Theme:String = null with get,set
member val RestrictedId:Nullable<Int32> = new Nullable<Int32>() with get,set
member val RestrictedResourceType:RestrictedResourceType = new RestrictedResourceType() with get,set
///<summary>
///Allows for a payment profile to be deleted
///</summary>
[<ApiMember(Description="Allows for a payment profile to be deleted", Name="AllowDeleteProfile", ParameterType="query")>]
member val AllowDeleteProfile:Nullable<Boolean> = new Nullable<Boolean>() with get,set
///<summary>
///Allows for a payment profile to be disabled
///</summary>
[<ApiMember(Description="Allows for a payment profile to be disabled", Name="AllowDisableProfile", ParameterType="query")>]
member val AllowDisableProfile:Nullable<Boolean> = new Nullable<Boolean>() with get,set
F# WalletTokenCreateEndpoint DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /sales/wallet/wallettokencreate HTTP/1.1 Host: clubready.com Accept: application/xml
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <WalletTokenCreateResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Web.Api.Sales.Wallet"> <Message xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Core.Api.Models">String</Message> <Success xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Core.Api.Models">false</Success> <WalletOrigin xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Sales.Wallet">String</WalletOrigin> <WalletToken xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Sales.Wallet">String</WalletToken> <WalletUrl xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Sales.Wallet">String</WalletUrl> </WalletTokenCreateResponse>