Skip to content

Latest commit

 

History

History
200 lines (149 loc) · 10.7 KB

ShopListingTranslationApi.md

File metadata and controls

200 lines (149 loc) · 10.7 KB

Swagger\Client\ShopListingTranslationApi

All URIs are relative to https://openapi.etsy.com

Method HTTP request Description
createListingTranslation POST /v3/application/shops/{shop_id}/listings/{listing_id}/translations/{language}
getListingTranslation GET /v3/application/shops/{shop_id}/listings/{listing_id}/translations/{language}
updateListingTranslation PUT /v3/application/shops/{shop_id}/listings/{listing_id}/translations/{language}

createListingTranslation

\Swagger\Client\Model\ListingTranslation createListingTranslation($shop_id, $listing_id, $language, $title, $description, $tags)

General ReleaseReport bug

This endpoint is ready for production use.

Creates a ListingTranslation by listing_id and language

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: api_key
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('x-api-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('x-api-key', 'Bearer');
// Configure OAuth2 access token for authorization: oauth2
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Swagger\Client\Api\ShopListingTranslationApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$shop_id = 56; // int | The unique positive non-zero numeric ID for an Etsy Shop.
$listing_id = 56; // int | The numeric ID for the [listing](/documentation/reference#tag/ShopListing) associated to this transaction.
$language = "language_example"; // string | The IETF language tag for the language of this translation. Ex: `de`, `en`, `es`, `fr`, `it`, `ja`, `nl`, `pl`, `pt`.
$title = "title_example"; // string | 
$description = "description_example"; // string | 
$tags = array("tags_example"); // string[] | 

try {
    $result = $apiInstance->createListingTranslation($shop_id, $listing_id, $language, $title, $description, $tags);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ShopListingTranslationApi->createListingTranslation: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
shop_id int The unique positive non-zero numeric ID for an Etsy Shop.
listing_id int The numeric ID for the listing associated to this transaction.
language string The IETF language tag for the language of this translation. Ex: `de`, `en`, `es`, `fr`, `it`, `ja`, `nl`, `pl`, `pt`.
title string [optional]
description string [optional]
tags string[] [optional]

Return type

\Swagger\Client\Model\ListingTranslation

Authorization

api_key, oauth2

HTTP request headers

  • Content-Type: application/x-www-form-urlencoded
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

getListingTranslation

\Swagger\Client\Model\ListingTranslation getListingTranslation($shop_id, $listing_id, $language)

General ReleaseReport bug

This endpoint is ready for production use.

Get a Translation for a Listing in the given language

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: api_key
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('x-api-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('x-api-key', 'Bearer');

$apiInstance = new Swagger\Client\Api\ShopListingTranslationApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$shop_id = 56; // int | The unique positive non-zero numeric ID for an Etsy Shop.
$listing_id = 56; // int | The numeric ID for the [listing](/documentation/reference#tag/ShopListing) associated to this transaction.
$language = "language_example"; // string | The IETF language tag for the language of this translation. Ex: `de`, `en`, `es`, `fr`, `it`, `ja`, `nl`, `pl`, `pt`.

try {
    $result = $apiInstance->getListingTranslation($shop_id, $listing_id, $language);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ShopListingTranslationApi->getListingTranslation: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
shop_id int The unique positive non-zero numeric ID for an Etsy Shop.
listing_id int The numeric ID for the listing associated to this transaction.
language string The IETF language tag for the language of this translation. Ex: `de`, `en`, `es`, `fr`, `it`, `ja`, `nl`, `pl`, `pt`.

Return type

\Swagger\Client\Model\ListingTranslation

Authorization

api_key

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

updateListingTranslation

\Swagger\Client\Model\ListingTranslation updateListingTranslation($shop_id, $listing_id, $language, $title, $description, $tags)

General ReleaseReport bug

This endpoint is ready for production use.

Updates a ListingTranslation by listing_id and language

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: api_key
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('x-api-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('x-api-key', 'Bearer');
// Configure OAuth2 access token for authorization: oauth2
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$apiInstance = new Swagger\Client\Api\ShopListingTranslationApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$shop_id = 56; // int | The unique positive non-zero numeric ID for an Etsy Shop.
$listing_id = 56; // int | The numeric ID for the [listing](/documentation/reference#tag/ShopListing) associated to this transaction.
$language = "language_example"; // string | The IETF language tag for the language of this translation. Ex: `de`, `en`, `es`, `fr`, `it`, `ja`, `nl`, `pl`, `pt`.
$title = "title_example"; // string | 
$description = "description_example"; // string | 
$tags = array("tags_example"); // string[] | 

try {
    $result = $apiInstance->updateListingTranslation($shop_id, $listing_id, $language, $title, $description, $tags);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ShopListingTranslationApi->updateListingTranslation: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
shop_id int The unique positive non-zero numeric ID for an Etsy Shop.
listing_id int The numeric ID for the listing associated to this transaction.
language string The IETF language tag for the language of this translation. Ex: `de`, `en`, `es`, `fr`, `it`, `ja`, `nl`, `pl`, `pt`.
title string [optional]
description string [optional]
tags string[] [optional]

Return type

\Swagger\Client\Model\ListingTranslation

Authorization

api_key, oauth2

HTTP request headers

  • Content-Type: application/x-www-form-urlencoded
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]