POST | /users/{UserId}/add-waiver | Add a waiver for a user. |
---|
namespace ClubReady.Web.Api
open System
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations
type RestrictedResourceType =
| Store = 0
| Chain = 1
| User = 2
| Undefined = 3
[<AllowNullLiteral>]
type AddUserWaiverRequest() =
///<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>
///Store ID
///</summary>
[<ApiMember(DataType="integer", Description="Store ID", IsRequired=true, Name="StoreId", ParameterType="query")>]
member val StoreId:Int32 = new Int32() with get,set
///<summary>
///ClubReady User ID
///</summary>
[<ApiMember(DataType="integer", Description="ClubReady User ID", IsRequired=true, Name="UserId", ParameterType="path")>]
member val UserId:Int32 = new Int32() with get,set
///<summary>
///Form ID
///</summary>
[<ApiMember(DataType="integer", Description="Form ID", Name="FormId", ParameterType="query")>]
member val FormId:Nullable<Int32> = new Nullable<Int32>() with get,set
///<summary>
///Base64 encoded PDF string
///</summary>
[<ApiMember(DataType="string", Description="Base64 encoded PDF string", IsRequired=true, Name="WaiverPdf", ParameterType="form")>]
member val WaiverPdf: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
[<AllowNullLiteral>]
type AddUserWaiverResponse() =
member val Success:Boolean = new Boolean() with get,set
member val Message:String = null with get,set
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.
POST /users/{UserId}/add-waiver HTTP/1.1
Host: clubready.com
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<AddUserWaiverRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Web.Api.Members.Model">
<ApiKey>String</ApiKey>
<FormId>0</FormId>
<StoreId>0</StoreId>
<UserId>0</UserId>
<WaiverPdf>String</WaiverPdf>
</AddUserWaiverRequest>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <AddUserWaiverResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ClubReady.Web.Api.Members.Model"> <Message>String</Message> <Success>false</Success> </AddUserWaiverResponse>