go get github.com/buroz/gon11
package main
import (
"fmt"
"github.com/buroz/gon11/src/n11"
)
func main() {
var client = n11.Client{}
user := client.Create("*appKey*", "*appSecret*")
cities := client.Services.CityService.GetCity("07")
fmt.Println(cities.Body.GetCityResponse.Result.Status)
categories := client.Services.CategoryService.GetTopLevelCategories(user)
if categories.Body.GetTopLevelCategoriesResponse.Result != "success" {
panic(categories.Body.GetTopLevelCategoriesResponse.Result.ErrorMessage)
}
for _, d := range categories.Body.GetTopLevelCategoriesResponse.CategoryList.Category {
fmt.Println(d.CategoryId, d.CategoryName)
}
}
- GetCities
- GetCity
- GetDistrict
- GetNeighborhoods
- GetCategoryAttributes
- GetCategoryAttributesId
- GetCategoryAttributeValue
- GetParentCategory
- GetSubCategories
- GetTopLevelCategories
- GetProductByProductId
- GetProductBySellerCode
- GetProductList
- Save Product
- SearchProducts
- DeleteProductById
- DeleteProductBySellerCode
- UpdateDiscountValueByProductId
- UpdateDiscountValueBySellerCode
- UpdateProductPriceById
- UpdateProductPriceBySellerCode
- UpdateProductBasic
- GetProductQuestionList
- GetProductQuestionDetail
- SaveProductAnswer
- ProductAllStatusCountsRequest
- ProductSellingService
- StartSellingProductByProductId
- StartSellingProductBySellerCode
- StopSellingProductByProductId
- StopSellingProductBySellerCode
- GetProductStockByProductId
- GetProductStockBySellerCode
- DeleteAndUpdateStockByStockAttributes
- UpdateStockByStockId
- UpdateStockByStockSellerCode
- IncreaseStockByStockAttributes
- IncreaseStockByStockId
- IncreaseStockByStockSellerCode
- DetailedOrderList
- OrderList
- OrderDetail
- OrderItemAccept
- OrderItemReject
- MakeOrderItemShipment
- GetShipmentCompanies
- GetShipmentTemplate
- CreateOrUpdateShipmentTemplate
- GetShipmentTemplateList
- GetSettlementList
- GetSettlementDetail
- TicketListingAssignedToSeller
- TicketListingBelongsToSeller
- TicketAnswer
- TicketCreate