Tbbn.Sdk
0.3.0
dotnet add package Tbbn.Sdk --version 0.3.0
NuGet\Install-Package Tbbn.Sdk -Version 0.3.0
<PackageReference Include="Tbbn.Sdk" Version="0.3.0" />
<PackageVersion Include="Tbbn.Sdk" Version="0.3.0" />
<PackageReference Include="Tbbn.Sdk" />
paket add Tbbn.Sdk --version 0.3.0
#r "nuget: Tbbn.Sdk, 0.3.0"
#:package Tbbn.Sdk@0.3.0
#addin nuget:?package=Tbbn.Sdk&version=0.3.0
#tool nuget:?package=Tbbn.Sdk&version=0.3.0
Tbbn.Sdk
.NET client for the TBBN Platform API. Publish listings, manage offers and trade
sessions, and verify webhooks. .NET 8, built on System.Net.Http and System.Text.Json —
no third-party dependencies. Async throughout.
Install
dotnet add package Tbbn.Sdk
Quick start
using Tbbn.Sdk;
var client = new TbbnClient(new TbbnClientOptions
{
BaseUrl = "https://api.tbbnetwork.com",
ApiKey = "sk_sandbox_...",
});
var listing = await client.Listings.UpsertAsync(new Dictionary<string, object?>
{
["merchantId"] = "...",
["merchantListingRef"] = "sku-1042",
["sellerId"] = "...",
["listingType"] = "BOTH",
["title"] = "Nike Air Max 90 — size 10, lightly worn",
["category"] = "Apparel",
["originalPrice"] = 150,
["requestedAmount"] = 25,
["currency"] = "USD",
["visibility"] = "GLOBAL",
});
var offers = await client.Offers.ListAsync(listing!.SellerId, TbbnClient.OfferDirection.received);
The core resources (listings, offers, trade sessions, merchants, sellers) return typed records;
the rest return object?. A complete runnable walkthrough is in
example/Basic.cs.
Authentication
Pass either an API key (ApiKey, issued to your merchant at
merchants.tbbnetwork.com) or a session token
(AccessToken, obtained through one of the auth sign-in flows). Sandbox keys
(sk_sandbox_…) work against the same API and never touch live data.
Webhooks
Verify every inbound delivery before trusting it. Pass the raw request body exactly as received — re-serialising the JSON changes the bytes and the signature will not match. Signatures are HMAC-SHA256 with a five-minute replay window.
var ok = Webhooks.VerifySignature(rawBody, Request.Headers["X-TBBN-Signature"]!, signingSecret);
Errors
Every non-2xx response throws TbbnApiException with Status, Code, RequestId, the message, and — for some errors — structured Details. Quote the request id when asking
for help with a specific call.
Resources
Auth, Merchants, ApiKeys, OAuthClients, OAuthLink, Sellers, Businesses, Branches, BusinessMerchantLinks, Space, Listings, MerchantFeed, Catalog, Media, Directory, Search, TradeEngine, Currency, Localization, Matching, Recommendations, Offers, TradeSessions, Checkout, Billing, Notifications, Webhooks, AuditLogs, Moderation, Fraud, Reputation, Reviews, Analytics, Features, Sandbox, Status. Each method maps one-to-one onto an API endpoint documented in the
API reference.
Support
Questions and bug reports: the developer community.
License
MIT © Trade By Barter Network, Inc.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
See CHANGELOG.md