joinCampaign
Join Campaign
Enable wallet to join specific campaign
/oderowallet/v1/campaigns/join
Usage and SDK Samples
curl -X POST\
-H "Accept: */*"\
-H "Content-Type: application/json"\
"https://sandbox-api-gateway.oderopay.com.tr/oderowallet/v1/campaigns/join"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.CampaignsApi;
import java.io.File;
import java.util.*;
public class CampaignsApiExample {
public static void main(String[] args) {
CampaignsApi apiInstance = new CampaignsApi();
JoinCampaignRestRequest body = ; // JoinCampaignRestRequest |
String xWalletNumber = xWalletNumber_example; // String | Wallet Number
String xApiKey = xApiKey_example; // String | API Key
BigDecimal xAuthVersion = 1.2; // BigDecimal | Auth version
String xRndKey = xRndKey_example; // String | Random key
String xSignature = xSignature_example; // String | Hashed signature
String xAccessToken = xAccessToken_example; // String | Access Token
try {
ResponseJoinCampaignRestResponse result = apiInstance.joinCampaign(body, xWalletNumber, xApiKey, xAuthVersion, xRndKey, xSignature, xAccessToken);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling CampaignsApi#joinCampaign");
e.printStackTrace();
}
}
}
import io.swagger.client.api.CampaignsApi;
public class CampaignsApiExample {
public static void main(String[] args) {
CampaignsApi apiInstance = new CampaignsApi();
JoinCampaignRestRequest body = ; // JoinCampaignRestRequest |
String xWalletNumber = xWalletNumber_example; // String | Wallet Number
String xApiKey = xApiKey_example; // String | API Key
BigDecimal xAuthVersion = 1.2; // BigDecimal | Auth version
String xRndKey = xRndKey_example; // String | Random key
String xSignature = xSignature_example; // String | Hashed signature
String xAccessToken = xAccessToken_example; // String | Access Token
try {
ResponseJoinCampaignRestResponse result = apiInstance.joinCampaign(body, xWalletNumber, xApiKey, xAuthVersion, xRndKey, xSignature, xAccessToken);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling CampaignsApi#joinCampaign");
e.printStackTrace();
}
}
}
JoinCampaignRestRequest *body = ; //
String *xWalletNumber = xWalletNumber_example; // Wallet Number
String *xApiKey = xApiKey_example; // API Key
BigDecimal *xAuthVersion = 1.2; // Auth version
String *xRndKey = xRndKey_example; // Random key
String *xSignature = xSignature_example; // Hashed signature
String *xAccessToken = xAccessToken_example; // Access Token (optional)
CampaignsApi *apiInstance = [[CampaignsApi alloc] init];
// Join Campaign
[apiInstance joinCampaignWith:body
xWalletNumber:xWalletNumber
xApiKey:xApiKey
xAuthVersion:xAuthVersion
xRndKey:xRndKey
xSignature:xSignature
xAccessToken:xAccessToken
completionHandler: ^(ResponseJoinCampaignRestResponse output, NSError* error) {
if (output) {
NSLog(@"%@", output);
}
if (error) {
NSLog(@"Error: %@", error);
}
}];
var WalletBffApi = require('wallet_bff_api');
var api = new WalletBffApi.CampaignsApi()
var body = ; // {{JoinCampaignRestRequest}}
var xWalletNumber = xWalletNumber_example; // {{String}} Wallet Number
var xApiKey = xApiKey_example; // {{String}} API Key
var xAuthVersion = 1.2; // {{BigDecimal}} Auth version
var xRndKey = xRndKey_example; // {{String}} Random key
var xSignature = xSignature_example; // {{String}} Hashed signature
var opts = {
'xAccessToken': xAccessToken_example // {{String}} Access Token
};
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
api.joinCampaign(bodyxWalletNumberxApiKeyxAuthVersionxRndKeyxSignature, opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace Example
{
public class joinCampaignExample
{
public void main()
{
var apiInstance = new CampaignsApi();
var body = new JoinCampaignRestRequest(); // JoinCampaignRestRequest |
var xWalletNumber = xWalletNumber_example; // String | Wallet Number
var xApiKey = xApiKey_example; // String | API Key
var xAuthVersion = 1.2; // BigDecimal | Auth version
var xRndKey = xRndKey_example; // String | Random key
var xSignature = xSignature_example; // String | Hashed signature
var xAccessToken = xAccessToken_example; // String | Access Token (optional)
try
{
// Join Campaign
ResponseJoinCampaignRestResponse result = apiInstance.joinCampaign(body, xWalletNumber, xApiKey, xAuthVersion, xRndKey, xSignature, xAccessToken);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling CampaignsApi.joinCampaign: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new Swagger\Client\ApiCampaignsApi();
$body = ; // JoinCampaignRestRequest |
$xWalletNumber = xWalletNumber_example; // String | Wallet Number
$xApiKey = xApiKey_example; // String | API Key
$xAuthVersion = 1.2; // BigDecimal | Auth version
$xRndKey = xRndKey_example; // String | Random key
$xSignature = xSignature_example; // String | Hashed signature
$xAccessToken = xAccessToken_example; // String | Access Token
try {
$result = $api_instance->joinCampaign($body, $xWalletNumber, $xApiKey, $xAuthVersion, $xRndKey, $xSignature, $xAccessToken);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling CampaignsApi->joinCampaign: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::CampaignsApi;
my $api_instance = WWW::SwaggerClient::CampaignsApi->new();
my $body = WWW::SwaggerClient::Object::JoinCampaignRestRequest->new(); # JoinCampaignRestRequest |
my $xWalletNumber = xWalletNumber_example; # String | Wallet Number
my $xApiKey = xApiKey_example; # String | API Key
my $xAuthVersion = 1.2; # BigDecimal | Auth version
my $xRndKey = xRndKey_example; # String | Random key
my $xSignature = xSignature_example; # String | Hashed signature
my $xAccessToken = xAccessToken_example; # String | Access Token
eval {
my $result = $api_instance->joinCampaign(body => $body, xWalletNumber => $xWalletNumber, xApiKey => $xApiKey, xAuthVersion => $xAuthVersion, xRndKey => $xRndKey, xSignature => $xSignature, xAccessToken => $xAccessToken);
print Dumper($result);
};
if ($@) {
warn "Exception when calling CampaignsApi->joinCampaign: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint
# create an instance of the API class
api_instance = swagger_client.CampaignsApi()
body = # JoinCampaignRestRequest |
xWalletNumber = xWalletNumber_example # String | Wallet Number
xApiKey = xApiKey_example # String | API Key
xAuthVersion = 1.2 # BigDecimal | Auth version
xRndKey = xRndKey_example # String | Random key
xSignature = xSignature_example # String | Hashed signature
xAccessToken = xAccessToken_example # String | Access Token (optional)
try:
# Join Campaign
api_response = api_instance.join_campaign(body, xWalletNumber, xApiKey, xAuthVersion, xRndKey, xSignature, xAccessToken=xAccessToken)
pprint(api_response)
except ApiException as e:
print("Exception when calling CampaignsApi->joinCampaign: %s\n" % e)
Parameters
Name | Description |
---|---|
x-access-token |
String
Access Token
|
x-wallet-number* |
String
Wallet Number
Required
|
x-api-key* |
String
API Key
Required
|
x-auth-version* |
BigDecimal
Auth version
Required
|
x-rnd-key* |
String
Random key
Required
|
x-signature* |
String
Hashed signature
Required
|
Name | Description |
---|---|
body * |