Beispiel #1
0
 public async Task SearchSinglePage(EtsyService etsyService)
 {
     var r = await etsyService.GetListingsPage(_searchExample, null, new GetListingsPageParameters
     {
         Limit  = 100,
         Offset = 0,
         Page   = 1
     });
 }
Beispiel #2
0
 public async Task GetAllShopListingsWithIncludes(EtsyService etsyService)
 {
     var r = await etsyService.GetAllShopListings(_shopExample, null, null, new GetListingsPageParameters
     {
         Limit    = 100,
         Offset   = 0,
         Page     = 1,
         Includes = "Images(url_75x75,url_170x135):1:0,Shop(shop_id)"
     }).ToArrayAsync();
 }
Beispiel #3
0
        public async Task SearchAllWithIncludes(EtsyService etsyService)
        {
            var r = await etsyService.GetAllListings(_searchExample, 891, new GetListingsPageParameters()
            {
                Includes = "Images(url_75x75,url_170x135):1:0,Shop(shop_id),ShippingInfo"
            }).ToArrayAsync();

            //var item = r.FirstOrDefault(p => p.listing_id == 974223362);

            //var usaTemplate = item.ShippingInfo.Where(p => p.destination_country_id == 209 || p.destination_country_id == null).ToArray();
        }
Beispiel #4
0
        public async Task CreateListing(EtsyService etsyService)
        {
            //var templates = await etsyService.GetUserShippingProfiles(_testUserShippingProfiles);

            //var template = templates.FirstOrDefault();

            var description =
                @"Test description"
            ;

            var title = "Test title";

            var price = 88.99f;

            await etsyService.CreateListing(new CreateListing
            {
                quantity             = 1,
                title                = title,
                description          = description,
                price                = price,
                shipping_template_id = 131535626742,
                taxonomy_id          = 6561,
                //shop_section_id = 32402445,
                non_taxable    = false,
                is_supply      = false,
                state          = CreateListingState.draft,
                tags           = new StringCollection(new[] { "testtag", "tag" }),
                who_made       = ListingWhoMade.i_did,
                when_made      = ListingWhenMade._2020_2021,
                recipient      = ListingRecipient.not_specified,
                processing_max = 2,
                processing_min = 1,
                Inventory      = new ListingInventory {
                    products = new ListingProduct[]
                    {
                        new ListingProduct()
                        {
                            sku = "TEST-SKU-123"
                        }
                    }
                }
            });
        }
Beispiel #5
0
 public async Task GetListingWithIncludes(EtsyService etsyService)
 {
     var r = await etsyService.GetListingsById(new[] { _listingExample }, CancellationToken.None, ListingAssociationIncludes.ShippingInfo | ListingAssociationIncludes.Shop | ListingAssociationIncludes.Images).ToArrayAsync();
 }
Beispiel #6
0
 public async Task GetListing(EtsyService etsyService)
 {
     var r = await etsyService.GetListingsById(new[] { _listingExample }).ToArrayAsync();
 }
Beispiel #7
0
 public async Task GetAllShopListings(EtsyService etsyService)
 {
     var r = await etsyService.GetAllShopListings(_shopExample).ToArrayAsync();
 }
Beispiel #8
0
        public async Task GetUserShippingProfiles(EtsyService etsyService)
        {
            var r = await etsyService.GetUserShippingProfiles(_testUserShippingProfiles);

            r.WriteCsv("shippingTemplates.csv");
        }
Beispiel #9
0
 public async Task GetTaxonomy(EtsyService etsyService)
 {
     var r = await etsyService.GetBuyerTaxonomies();
 }
Beispiel #10
0
 public async Task GetShops(EtsyService etsyService)
 {
     var r = await etsyService.GetShops(new [] { "CMoreDesignsYourway" });
 }
Beispiel #11
0
 public async Task FindTaxonomyById(EtsyService etsyService)
 {
     var r = await etsyService.FindTaxonomyById(_taxonomyIdExample);
 }
Beispiel #12
0
 public async Task FindTaxonomy(EtsyService etsyService)
 {
     var r = await etsyService.FindTaxonomyByPath("test");
 }
Beispiel #13
0
 public async Task GetUserAccessScopes(EtsyService etsyService)
 {
     var r = await etsyService.GetUserAccessScopes();
 }
Beispiel #14
0
 public async Task GetListingWithIncludesString(EtsyService etsyService)
 {
     var r = await etsyService.GetListingsByIdStringIncludes(new[] { _listingExample }, CancellationToken.None, "Images(url_75x75,url_170x135):1:0,Shop(shop_id)").ToArrayAsync();
 }
Beispiel #15
0
 public async Task SearchAll(EtsyService etsyService)
 {
     var r = await etsyService.GetAllListings(_searchExample, 891).ToArrayAsync();
 }
Beispiel #16
0
 public async Task GetListingWithVariations(EtsyService etsyService)
 {
     var r = await etsyService.GetListingsById(new[] { _listingExample }, CancellationToken.None, ListingAssociationIncludes.Variations).ToArrayAsync();
 }
Beispiel #17
0
        public async Task GetAllTaxonomies(EtsyService etsyService)
        {
            var r = await etsyService.GetBuyerTaxonomiesFlattened();

            r.WriteCsv("EtsyTaxonomies.csv");
        }