An open API service indexing awesome lists of open source software.

https://github.com/guibranco/vtex-sdk-dotnet

πŸ›’ βš™οΈ VTEX platform .NET SDK
https://github.com/guibranco/vtex-sdk-dotnet

api dotnet dotnet-core dotnetcore dotnetframework e-commerce ecommerce hacktoberfest sdk vtex vtex-api

Last synced: 6 months ago
JSON representation

πŸ›’ βš™οΈ VTEX platform .NET SDK

Awesome Lists containing this project

README

          

# VTEX SDK

πŸ›’ βš™οΈ [VTEX](https://vtex.com) platform .NET SDK.

[![GitHub license](https://img.shields.io/github/license/guibranco/VTEX-SDK-dotnet)](https://github.com/guibranco/VTEX-SDK-dotnet)
[![Time tracker](https://wakatime.com/badge/github/guibranco/VTEX-SDK-dotnet.svg)](https://wakatime.com/badge/github/guibranco/VTEX-SDK-dotnet)

![VTEX logo](https://raw.githubusercontent.com/guibranco/VTEX-SDK-dotnet/main/logo.png)

## CI/CD

| Build status | Last commit | Tests | Coverage | Code Smells | LoC |
|--------------|-------------|-------|----------|-------------|-----|
| [![Build status](https://ci.appveyor.com/api/projects/status/kuso66xs0ljrcxfn/branch/main?svg=true)](https://ci.appveyor.com/project/guibranco/vtex-sdk-dotnet/branch/main) | [![GitHub last commit](https://img.shields.io/github/last-commit/guibranco/VTEX-SDK-dotnet/main)](https://github.com/guibranco/VTEX-SDK-dotnet) | ![AppVeyor tests (branch)](https://img.shields.io/appveyor/tests/guibranco/vtex-sdk-dotnet/main?compact_message) | [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=coverage)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet) | [![Code Smells](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=code_smells)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet) | [![Lines of Code](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=ncloc)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)

## Code Quality

[![Codacy Badge](https://app.codacy.com/project/badge/Grade/0db3e765696d4ce18f223aacc38aed47)](https://www.codacy.com/gh/guibranco/VTEX-SDK-dotnet/dashboard?utm_source=github.com&utm_medium=referral&utm_content=guibranco/VTEX-SDK-dotnet&utm_campaign=Badge_Grade)
[![Codacy Badge](https://app.codacy.com/project/badge/Coverage/0db3e765696d4ce18f223aacc38aed47)](https://www.codacy.com/gh/guibranco/VTEX-SDK-dotnet/dashboard?utm_source=github.com&utm_medium=referral&utm_content=guibranco/VTEX-SDK-dotnet&utm_campaign=Badge_Coverage)

[![codecov](https://codecov.io/gh/guibranco/VTEX-SDK-dotnet/branch/main/graph/badge.svg)](https://codecov.io/gh/guibranco/VTEX-SDK-dotnet)
[![CodeFactor](https://www.codefactor.io/repository/github/guibranco/VTEX-SDK-dotnet/badge)](https://www.codefactor.io/repository/github/guibranco/VTEX-SDK-dotnet)

[![Maintainability](https://api.codeclimate.com/v1/badges/adc8920697c01bc3e108/maintainability)](https://codeclimate.com/github/guibranco/VTEX-SDK-dotnet/maintainability)
[![Test Coverage](https://api.codeclimate.com/v1/badges/adc8920697c01bc3e108/test_coverage)](https://codeclimate.com/github/guibranco/VTEX-SDK-dotnet/test_coverage)

[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=alert_status)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)
[![Maintainability Rating](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=sqale_rating)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)

[![Technical Debt](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=sqale_index)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)
[![Duplicated Lines (%)](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=duplicated_lines_density)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)

[![Reliability Rating](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=reliability_rating)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)
[![Security Rating](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=security_rating)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)

[![Bugs](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=bugs)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)
[![Vulnerabilities](https://sonarcloud.io/api/project_badges/measure?project=guibranco_VTEX-SDK-dotnet&metric=vulnerabilities)](https://sonarcloud.io/dashboard?id=guibranco_VTEX-SDK-dotnet)

---

## Installation

### Github Releases

[![GitHub last release](https://img.shields.io/github/release-date/guibranco/VTEX-SDK-dotnet.svg?style=flat)](https://github.com/guibranco/VTEX-SDK-dotnet) [![Github All Releases](https://img.shields.io/github/downloads/guibranco/VTEX-SDK-dotnet/total.svg?style=flat)](https://github.com/guibranco/VTEX-SDK-dotnet)

Download the latest `.zip` file from the [Releases](https://github.com/GuiBranco/VTEX-SDK-dotnet/releases) page.

### Nuget package manager

| Package | Version | Downloads |
|------------------|:-------:|:-------:|
| **VTEX** | [![VTEX NuGet Version](https://img.shields.io/nuget/v/VTEX.svg?style=flat)](https://www.nuget.org/packages/VTEX/) | [![VTEX NuGet Downloads](https://img.shields.io/nuget/dt/VTEX.svg?style=flat)](https://www.nuget.org/packages/VTEX/) |
| **VTEX.Health** | [![VTEX Health NuGet Version](https://img.shields.io/nuget/v/VTEX.Health.svg?style=flat)](https://www.nuget.org/packages/VTEX.Health/) | [![VTEX Health NuGet Downloads](https://img.shields.io/nuget/dt/VTEX.Health.svg?style=flat)](https://www.nuget.org/packages/VTEX.Health/) |

---

## Features

- Full implementation of VTEX API.
- Refer to [VTEX Developer Docs](https://developers.vtex.com/) for more information.

---

## Usage

### Dependency Injection (IoC)

Register the VTEX Service using the `CrispyWaffle` toolkit's [Service Locator](https://guibranco.github.io/CrispyWaffle/user-guide/serviceLocator/):

```csharp
var connectionVtex = new Connection(); // Fill in your details
ServiceLocator.Register(() => new VTEXContext(connectionVtex), LifeStyle.Singleton);
```

#### Constructor Injection

```csharp
public class MyClass
{
private readonly VTEXContext _vtexContext;

public MyClass(VTEXContext vtexContext)
{
_vtexContext = vtexContext ?? throw new ArgumentNullException(nameof(vtexContext));
}
}
```

#### Manual Resolution

```csharp
var vtexContext = ServiceLocator.Resolve();
```
---

### Authentication

Authenticate with VTEX platform API keys. Refer to this [tutorial](https://help.vtex.com/tutorial/creating-appkeys-and-apptokens-to-authenticate-integrations--43tQeyQJgAKGEuCqQKAOI2).

```csharp
var vtex = new VTEXContext("store name", "app-key-xyz", "app-token-secret-hash");
var order = vtex.GetOrder("V-123456789-01");
Console.WriteLine($"Sequence: {order.Sequence} | Value: {order.Value}");
```

---

## Support

If you need help, feel free to [open an issue](https://github.com/guibranco/VTEX-SDK-dotnet/issues/new).

---

## Contributing

Contributions are welcome! Check out the [CONTRIBUTING.md](CONTRIBUTING.md) guide for details.

---

## Contributors

Thanks to all contributors! πŸ’™





guibranco


Guilherme Branco Stracini




joaovaladares


JoΓ£o VΓ­tor Valadares




viktoriussuwandi


Viktorius Suwandi



### Bots





dependabot[bot]


dependabot[bot]




github-actions[bot]


github-actions[bot]




penify-dev[bot]


penify-dev[bot]




stack-file[bot]


stack-file[bot]




codefactor-io[bot]


codefactor-io[bot]




snyk-bot


Snyk bot