apiAddProductToCartServiceProductidPost
/api/AddProductToCartService/{Productid}
Usage and SDK Samples
curl -X POST "https://api.apieco.ir/postbar/api/AddProductToCartService/{Productid}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.AddProductToCartServiceApi;
import java.io.File;
import java.util.*;
public class AddProductToCartServiceApiExample {
public static void main(String[] args) {
AddProductToCartServiceApi apiInstance = new AddProductToCartServiceApi();
String apiecoKey = apiecoKey_example; // String | apikey for use API
String token = token_example; // String | توکن کاربر
String productid = productid_example; // String | کلید محصول
try {
apiInstance.apiAddProductToCartServiceProductidPost(apiecoKey, token, productid);
} catch (ApiException e) {
System.err.println("Exception when calling AddProductToCartServiceApi#apiAddProductToCartServiceProductidPost");
e.printStackTrace();
}
}
}
import io.swagger.client.api.AddProductToCartServiceApi;
public class AddProductToCartServiceApiExample {
public static void main(String[] args) {
AddProductToCartServiceApi apiInstance = new AddProductToCartServiceApi();
String apiecoKey = apiecoKey_example; // String | apikey for use API
String token = token_example; // String | توکن کاربر
String productid = productid_example; // String | کلید محصول
try {
apiInstance.apiAddProductToCartServiceProductidPost(apiecoKey, token, productid);
} catch (ApiException e) {
System.err.println("Exception when calling AddProductToCartServiceApi#apiAddProductToCartServiceProductidPost");
e.printStackTrace();
}
}
}
String *apiecoKey = apiecoKey_example; // apikey for use API (default to WsLdHK46I5Wfr5xgI0ynjjyiw9Fyhydu)
String *token = token_example; // توکن کاربر (default to WsLdHK46I5Wfr5xgI0ynjjyiw9Fyhydu)
String *productid = productid_example; // کلید محصول
AddProductToCartServiceApi *apiInstance = [[AddProductToCartServiceApi alloc] init];
[apiInstance apiAddProductToCartServiceProductidPostWith:apiecoKey
token:token
productid:productid
completionHandler: ^(NSError* error) {
if (error) {
NSLog(@"Error: %@", error);
}
}];
var _ = require('_______');
var api = new _.AddProductToCartServiceApi()
var apiecoKey = apiecoKey_example; // {String} apikey for use API
var token = token_example; // {String} توکن کاربر
var productid = productid_example; // {String} کلید محصول
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
api.apiAddProductToCartServiceProductidPost(apiecoKey, token, productid, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace Example
{
public class apiAddProductToCartServiceProductidPostExample
{
public void main()
{
var apiInstance = new AddProductToCartServiceApi();
var apiecoKey = apiecoKey_example; // String | apikey for use API (default to WsLdHK46I5Wfr5xgI0ynjjyiw9Fyhydu)
var token = token_example; // String | توکن کاربر (default to WsLdHK46I5Wfr5xgI0ynjjyiw9Fyhydu)
var productid = productid_example; // String | کلید محصول
try
{
apiInstance.apiAddProductToCartServiceProductidPost(apiecoKey, token, productid);
}
catch (Exception e)
{
Debug.Print("Exception when calling AddProductToCartServiceApi.apiAddProductToCartServiceProductidPost: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new Swagger\Client\Api\AddProductToCartServiceApi();
$apiecoKey = apiecoKey_example; // String | apikey for use API
$token = token_example; // String | توکن کاربر
$productid = productid_example; // String | کلید محصول
try {
$api_instance->apiAddProductToCartServiceProductidPost($apiecoKey, $token, $productid);
} catch (Exception $e) {
echo 'Exception when calling AddProductToCartServiceApi->apiAddProductToCartServiceProductidPost: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::AddProductToCartServiceApi;
my $api_instance = WWW::SwaggerClient::AddProductToCartServiceApi->new();
my $apiecoKey = apiecoKey_example; # String | apikey for use API
my $token = token_example; # String | توکن کاربر
my $productid = productid_example; # String | کلید محصول
eval {
$api_instance->apiAddProductToCartServiceProductidPost(apiecoKey => $apiecoKey, token => $token, productid => $productid);
};
if ($@) {
warn "Exception when calling AddProductToCartServiceApi->apiAddProductToCartServiceProductidPost: $@\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.AddProductToCartServiceApi()
apiecoKey = apiecoKey_example # String | apikey for use API (default to WsLdHK46I5Wfr5xgI0ynjjyiw9Fyhydu)
token = token_example # String | توکن کاربر (default to WsLdHK46I5Wfr5xgI0ynjjyiw9Fyhydu)
productid = productid_example # String | کلید محصول
try:
api_instance.api_add_product_to_cart_service_productid_post(apiecoKey, token, productid)
except ApiException as e:
print("Exception when calling AddProductToCartServiceApi->apiAddProductToCartServiceProductidPost: %s\n" % e)
Parameters
Path parameters
Name | Description |
---|---|
Productid* |
String
کلید محصول
Required
|
Header parameters
Name | Description |
---|---|
apieco-key* |
String
apikey for use API
Required
|
Token* |
String
توکن کاربر
Required
|