-
Notifications
You must be signed in to change notification settings - Fork 195
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
727 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
using static FikaAmazonAPI.AmazonSpApiSDK.Models.ListingsItems.ListingsItemPutRequest; | ||
|
||
namespace FikaAmazonAPI.SampleCode | ||
{ | ||
internal class ProductTypeSample | ||
{ | ||
|
||
AmazonConnection amazonConnection; | ||
public ProductTypeSample(AmazonConnection amazonConnection) | ||
{ | ||
this.amazonConnection = amazonConnection; | ||
} | ||
|
||
|
||
private void SearchDefinitionsProductTypes() | ||
{ | ||
var list = amazonConnection.ProductType.SearchDefinitionsProductTypes( | ||
new Parameter.ProductTypes.SearchDefinitionsProductTypesParameter() | ||
{ | ||
keywords = new List<string> { String.Empty }, | ||
}); | ||
|
||
} | ||
private void GetDefinitionsProductType() | ||
{ | ||
var def = amazonConnection.ProductType.GetDefinitionsProductType( | ||
new Parameter.ProductTypes.GetDefinitionsProductTypeParameter() | ||
{ | ||
productType = "PRODUCT", | ||
requirements = RequirementsEnum.LISTING, | ||
locale = AmazonSpApiSDK.Models.ProductTypes.LocaleEnum.en_US | ||
}); | ||
} | ||
|
||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
158 changes: 158 additions & 0 deletions
158
Source/FikaAmazonAPI/AmazonSpApiSDK/Models/ProductTypes/LocaleEnum.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,158 @@ | ||
using System.Runtime.Serialization; | ||
|
||
namespace FikaAmazonAPI.AmazonSpApiSDK.Models.ProductTypes | ||
{ | ||
public enum LocaleEnum | ||
{ | ||
/// <summary> | ||
/// Arabic | ||
/// </summary> | ||
[EnumMember(Value = "ar")] | ||
ar, | ||
/// <summary> | ||
/// Arabic (U.A.E.) | ||
/// </summary> | ||
[EnumMember(Value = "ar_AE")] ar_AE, | ||
/// <summary> | ||
/// German | ||
/// </summary> | ||
[EnumMember(Value = "de")] de, | ||
/// <summary> | ||
/// German (Germany) | ||
/// </summary> | ||
[EnumMember(Value = "de_DE")] de_DE, | ||
/// <summary> | ||
/// English | ||
/// </summary> | ||
[EnumMember(Value = "en")] en, | ||
/// <summary> | ||
/// English (U.A.E.) | ||
/// </summary> | ||
[EnumMember(Value = "en_AE")] en_AE, | ||
/// <summary> | ||
/// English (Australia) | ||
/// </summary> | ||
[EnumMember(Value = "en_AU")] en_AU, | ||
/// <summary> | ||
/// English (Canada) | ||
/// </summary> | ||
[EnumMember(Value = "en_CA")] en_CA, | ||
/// <summary> | ||
/// English (United Kingdom) | ||
/// </summary> | ||
[EnumMember(Value = "en_GB")] en_GB, | ||
/// <summary> | ||
/// English (India) | ||
/// </summary> | ||
[EnumMember(Value = "en_IN")] en_IN, | ||
/// <summary> | ||
/// English (Singapore) | ||
/// </summary> | ||
[EnumMember(Value = "en_SG")] en_SG, | ||
/// <summary> | ||
/// English (United States) | ||
/// </summary> | ||
[EnumMember(Value = "en_US")] en_US, | ||
/// <summary> | ||
/// Spanish | ||
/// </summary> | ||
[EnumMember(Value = "es")] es, | ||
/// <summary> | ||
/// Spanish (Spain) | ||
/// </summary> | ||
[EnumMember(Value = "es_ES")] es_ES, | ||
/// <summary> | ||
/// Spanish (Mexico) | ||
/// </summary> | ||
[EnumMember(Value = "es_MX")] es_MX, | ||
/// <summary> | ||
/// Spanish (United States) | ||
/// </summary> | ||
[EnumMember(Value = "es_US")] es_US, | ||
/// <summary> | ||
/// French | ||
/// </summary> | ||
[EnumMember(Value = "fr")] fr, | ||
/// <summary> | ||
/// French (Canada) | ||
/// </summary> | ||
[EnumMember(Value = "fr_CA")] fr_CA, | ||
/// <summary> | ||
/// French (France) | ||
/// </summary> | ||
[EnumMember(Value = "fr_FR")] fr_FR, | ||
/// <summary> | ||
/// Italian | ||
/// </summary> | ||
[EnumMember(Value = "it")] it, | ||
/// <summary> | ||
/// Italian (Italy) | ||
/// </summary> | ||
[EnumMember(Value = "it_IT")] it_IT, | ||
/// <summary> | ||
/// Japanese | ||
/// </summary> | ||
[EnumMember(Value = "ja")] ja, | ||
/// <summary> | ||
/// Japanese (Japan) | ||
/// </summary> | ||
[EnumMember(Value = "ja_JP")] ja_JP, | ||
/// <summary> | ||
/// Dutch | ||
/// </summary> | ||
[EnumMember(Value = "nl")] nl, | ||
/// <summary> | ||
/// Dutch (Netherlands) | ||
/// </summary> | ||
[EnumMember(Value = "nl_NL")] nl_NL, | ||
/// <summary> | ||
/// Polish | ||
/// </summary> | ||
[EnumMember(Value = "pl")] pl, | ||
/// <summary> | ||
/// Polish (Poland) | ||
/// </summary> | ||
[EnumMember(Value = "pl_PL")] pl_PL, | ||
/// <summary> | ||
/// Portuguese | ||
/// </summary> | ||
[EnumMember(Value = "pt")] pt, | ||
/// <summary> | ||
/// Portuguese (Brazil) | ||
/// </summary> | ||
[EnumMember(Value = "pt_BR")] pt_BR, | ||
/// <summary> | ||
/// Portuguese (Portugal) | ||
/// </summary> | ||
[EnumMember(Value = "pt_PT")] pt_PT, | ||
/// <summary> | ||
/// Swedish | ||
/// </summary> | ||
[EnumMember(Value = "sv")] sv, | ||
/// <summary> | ||
/// Swedish (Sweden) | ||
/// </summary> | ||
[EnumMember(Value = "sv_SE")] sv_SE, | ||
/// <summary> | ||
/// Turkish | ||
/// </summary> | ||
[EnumMember(Value = "tr")] tr, | ||
/// <summary> | ||
/// Turkish (Turkey) | ||
/// </summary> | ||
[EnumMember(Value = "tr_TR")] tr_TR, | ||
/// <summary> | ||
/// Chinese | ||
/// </summary> | ||
[EnumMember(Value = "zh")] zh, | ||
/// <summary> | ||
/// Chinese (Simplified) | ||
/// </summary> | ||
[EnumMember(Value = "zh_CN")] zh_CN, | ||
/// <summary> | ||
/// Chinese (Traditional) | ||
/// </summary> | ||
[EnumMember(Value = "zh_TW")] zh_TW, | ||
|
||
} | ||
} |
56 changes: 56 additions & 0 deletions
56
Source/FikaAmazonAPI/AmazonSpApiSDK/Models/ProductTypes/ProductType.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
using Newtonsoft.Json; | ||
using System.Collections.Generic; | ||
using System.Runtime.Serialization; | ||
using System.Text; | ||
|
||
namespace FikaAmazonAPI.AmazonSpApiSDK.Models.ProductTypes | ||
{ | ||
|
||
/// <summary> | ||
/// An Amazon product type with a definition available. | ||
/// </summary> | ||
[DataContract] | ||
public class ProductType | ||
{ | ||
/// <summary> | ||
/// The name of the Amazon product type. | ||
/// </summary> | ||
/// <value>The name of the Amazon product type.</value> | ||
[DataMember(Name = "name", EmitDefaultValue = false)] | ||
[JsonProperty(PropertyName = "name")] | ||
public string Name { get; set; } | ||
|
||
/// <summary> | ||
/// The Amazon marketplace identifiers for which the product type definition is available. | ||
/// </summary> | ||
/// <value>The Amazon marketplace identifiers for which the product type definition is available.</value> | ||
[DataMember(Name = "marketplaceIds", EmitDefaultValue = false)] | ||
[JsonProperty(PropertyName = "marketplaceIds")] | ||
public List<string> MarketplaceIds { get; set; } | ||
|
||
|
||
/// <summary> | ||
/// Get the string presentation of the object | ||
/// </summary> | ||
/// <returns>String presentation of the object</returns> | ||
public override string ToString() | ||
{ | ||
var sb = new StringBuilder(); | ||
sb.Append("class ProductType {\n"); | ||
sb.Append(" Name: ").Append(Name).Append("\n"); | ||
sb.Append(" MarketplaceIds: ").Append(MarketplaceIds).Append("\n"); | ||
sb.Append("}\n"); | ||
return sb.ToString(); | ||
} | ||
|
||
/// <summary> | ||
/// Get the JSON string presentation of the object | ||
/// </summary> | ||
/// <returns>JSON string presentation of the object</returns> | ||
public string ToJson() | ||
{ | ||
return JsonConvert.SerializeObject(this, Formatting.Indented); | ||
} | ||
|
||
} | ||
} |
Oops, something went wrong.