All URIs are relative to https://api.flipdish.co
| Method | HTTP request | Description |
|---|---|---|
| CreateVoucher | POST /api/v1.0/vouchers/{appId} | |
| GetVoucherByCode | GET /api/v1.0/{appId}/vouchers/code/{code} | |
| GetVoucherById | GET /api/v1.0/vouchers/{voucherId} | |
| GetVoucherStatsById | GET /api/v1.0/vouchers/stats/{voucherId} | |
| GetVoucherValidityPeriods | GET /api/v1.0/{appId}/vouchers/{voucherId}/validity-periods | |
| GetVouchers | GET /api/v1.0/{appId}/vouchers/summaries | |
| GetVouchersByCustomerForApp | GET /api/v1.0/vouchers/{appId}/customer/{customerId} | |
| SetVoucherValidityPeriodsSimplified | POST /api/v1.0/{appId}/vouchers/{voucherId}/validity-periods-simplified | |
| UpdateVoucher | POST /api/v1.0/vouchers/{voucherId} | |
| UpdateVoucherUsage | POST /api/v1.0/{appId}/vouchers/{voucherId}/usage |
RestApiResultVoucherWithStats CreateVoucher (string appId, CreateVoucher voucher)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class CreateVoucherExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var appId = appId_example; // string |
var voucher = new CreateVoucher(); // CreateVoucher |
try
{
RestApiResultVoucherWithStats result = apiInstance.CreateVoucher(appId, voucher);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.CreateVoucher: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| appId | string | ||
| voucher | CreateVoucher |
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestApiResultVoucher GetVoucherByCode (string appId, string code)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class GetVoucherByCodeExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var appId = appId_example; // string |
var code = code_example; // string |
try
{
RestApiResultVoucher result = apiInstance.GetVoucherByCode(appId, code);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.GetVoucherByCode: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| appId | string | ||
| code | string |
- Content-Type: Not defined
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestApiResultVoucherWithStats GetVoucherById (int? voucherId)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class GetVoucherByIdExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var voucherId = 56; // int? |
try
{
RestApiResultVoucherWithStats result = apiInstance.GetVoucherById(voucherId);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.GetVoucherById: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| voucherId | int? |
- Content-Type: Not defined
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestApiArrayResultVoucherDataPoint GetVoucherStatsById (int? voucherId, string aggregateDataBy, int? dataPointLimit = null)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class GetVoucherStatsByIdExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var voucherId = 56; // int? |
var aggregateDataBy = aggregateDataBy_example; // string |
var dataPointLimit = 56; // int? | (optional)
try
{
RestApiArrayResultVoucherDataPoint result = apiInstance.GetVoucherStatsById(voucherId, aggregateDataBy, dataPointLimit);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.GetVoucherStatsById: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| voucherId | int? | ||
| aggregateDataBy | string | ||
| dataPointLimit | int? | [optional] |
RestApiArrayResultVoucherDataPoint
- Content-Type: Not defined
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void GetVoucherValidityPeriods (string appId, int? voucherId)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class GetVoucherValidityPeriodsExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var appId = appId_example; // string |
var voucherId = 56; // int? |
try
{
apiInstance.GetVoucherValidityPeriods(appId, voucherId);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.GetVoucherValidityPeriods: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| appId | string | ||
| voucherId | int? |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestApiPaginationResultVoucherSummary GetVouchers (string appId, int? pageIndex = null, int? pageSize = null, List searchCodes = null, List statusSearch = null, List typeSearch = null, List subTypeSearch = null, List<int?> storeIds = null, List channelRestrictions = null)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class GetVouchersExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var appId = appId_example; // string |
var pageIndex = 56; // int? | (optional)
var pageSize = 56; // int? | (optional)
var searchCodes = new List<string>(); // List<string> | (optional)
var statusSearch = statusSearch_example; // List<string> | (optional)
var typeSearch = typeSearch_example; // List<string> | (optional)
var subTypeSearch = subTypeSearch_example; // List<string> | (optional)
var storeIds = new List<int?>(); // List<int?> | (optional)
var channelRestrictions = channelRestrictions_example; // List<string> | (optional)
try
{
RestApiPaginationResultVoucherSummary result = apiInstance.GetVouchers(appId, pageIndex, pageSize, searchCodes, statusSearch, typeSearch, subTypeSearch, storeIds, channelRestrictions);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.GetVouchers: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| appId | string | ||
| pageIndex | int? | [optional] | |
| pageSize | int? | [optional] | |
| searchCodes | List<string> | [optional] | |
| statusSearch | List<string> | [optional] | |
| typeSearch | List<string> | [optional] | |
| subTypeSearch | List<string> | [optional] | |
| storeIds | List<int?> | [optional] | |
| channelRestrictions | List<string> | [optional] |
RestApiPaginationResultVoucherSummary
- Content-Type: Not defined
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestApiArrayResultVoucherSummary GetVouchersByCustomerForApp (string appId, int? customerId)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class GetVouchersByCustomerForAppExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var appId = appId_example; // string |
var customerId = 56; // int? |
try
{
RestApiArrayResultVoucherSummary result = apiInstance.GetVouchersByCustomerForApp(appId, customerId);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.GetVouchersByCustomerForApp: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| appId | string | ||
| customerId | int? |
RestApiArrayResultVoucherSummary
- Content-Type: Not defined
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void SetVoucherValidityPeriodsSimplified (string appId, int? voucherId, SetVoucherValidityPeriodsSimplifiedRequest request)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class SetVoucherValidityPeriodsSimplifiedExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var appId = appId_example; // string |
var voucherId = 56; // int? |
var request = new SetVoucherValidityPeriodsSimplifiedRequest(); // SetVoucherValidityPeriodsSimplifiedRequest |
try
{
apiInstance.SetVoucherValidityPeriodsSimplified(appId, voucherId, request);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.SetVoucherValidityPeriodsSimplified: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| appId | string | ||
| voucherId | int? | ||
| request | SetVoucherValidityPeriodsSimplifiedRequest |
void (empty response body)
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestApiResultVoucherWithStats UpdateVoucher (int? voucherId, UpdateVoucher voucher, List<int?> storeId = null, int? percentValue = null, double? lumpValue = null, double? maxDiscountAmount = null)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class UpdateVoucherExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var voucherId = 56; // int? |
var voucher = new UpdateVoucher(); // UpdateVoucher |
var storeId = new List<int?>(); // List<int?> | (optional)
var percentValue = 56; // int? | (optional)
var lumpValue = 1.2; // double? | (optional)
var maxDiscountAmount = 1.2; // double? | (optional)
try
{
RestApiResultVoucherWithStats result = apiInstance.UpdateVoucher(voucherId, voucher, storeId, percentValue, lumpValue, maxDiscountAmount);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.UpdateVoucher: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| voucherId | int? | ||
| voucher | UpdateVoucher | ||
| storeId | List<int?> | [optional] | |
| percentValue | int? | [optional] | |
| lumpValue | double? | [optional] | |
| maxDiscountAmount | double? | [optional] |
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void UpdateVoucherUsage (string appId, int? voucherId, UpdateVoucherUsage voucherUsage)
using System;
using System.Diagnostics;
using Flipdish.Api;
using Flipdish.Client;
using Flipdish.Model;
namespace Example
{
public class UpdateVoucherUsageExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new VouchersApi();
var appId = appId_example; // string |
var voucherId = 56; // int? |
var voucherUsage = new UpdateVoucherUsage(); // UpdateVoucherUsage |
try
{
apiInstance.UpdateVoucherUsage(appId, voucherId, voucherUsage);
}
catch (Exception e)
{
Debug.Print("Exception when calling VouchersApi.UpdateVoucherUsage: " + e.Message );
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| appId | string | ||
| voucherId | int? | ||
| voucherUsage | UpdateVoucherUsage |
void (empty response body)
- Content-Type: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
- Accept: application/json, text/json, application/xml, text/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]