Skip to content

.NET library for interacting with Lamoda B2B Platform

License

Notifications You must be signed in to change notification settings

loyvsc/LamodaB2B.NET

Repository files navigation

LamodaB2B.NET

.NET library for interacting with the Lamoda B2B Platform API

Installation

Download from NuGet

Package Manager
NuGet\Install-Package LamodaB2B.NET -Version *version_number*
.NET CLI
dotnet add package LamodaB2B.NET --version *version_number*

Features

  • Orders:
    • Get all orders
    • Get detailed order
    • Update order / order item status
    • Create order
    • Add partner order number
    • Update custom info
    • Get / set order delivery method
    • Get allowed shipment methods and intervals
    • Get allowed pickup points
    • Send notifications
  • Shipments:
    • Get shipments
    • Get detailed shipment
    • Get shipment items
    • Create shipment (basic / fulfilment / pack shipment)
    • Send shipment status notification
    • Set shipment status
  • Stock: get / set stock states
  • Nomenclatures:
    • Get nomenclatures
    • Create nomenclature (basic or pack nomenclature)
    • Update nomenclature
  • Fbs:
    • Get shipment products / packages
    • Generate label
  • Fbo:
    • Get sell settings
    • Update sell settings
  • Dbs: add shipment info
  • Certificates:
    • Generate certificate
    • Get certificates
    • Get balance
    • Change certificates status

Usage

There are several samples. The principle of working with the library is shown below.

Authorization

var client = new LamodaDemoClient();
var authorizationRequest = new AuthorizationRequest()
{
    GrantType = GrantType.ClientCredentials,
    СlientId = "my-client-id",
    ClientSecret = "my-client-secret"
};

try
{
    await client.AuthorizeAsync(authorizationRequest);
}
catch (LamodaException ex)
{
    Console.WriteLine(ex.Message);
}

Get orders

...
await client.AuthorizeAsync(authorizationRequest);
...

try
{
    var ordersService = new OrdersService(client);
    var orders = await ordersService.GetOrders();
}
catch (LamodaException ex)
{
    Console.WriteLine(ex.Message);
}

About

.NET library for interacting with Lamoda B2B Platform

Resources

License

Stars

Watchers

Forks

Languages