8000 GitHub - Hochfrequenz/TransformerBeeClient.NET at v0.1.1
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Hochfrequenz/TransformerBeeClient.NET

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 

Repository files navigation

transformer.bee Client (.NET)

This library is a .NET HTTP client for transformer.bee aka edifact-bo4e-converter.

It allows you to convert EDIFACT messages to BO4E and vice versa by speaking to Hochfreqeunz's transformer.bee service. Note that the actual conversion happens in the transformer.bee service/backend, this library only provides a convenient way to use its API.

How to use this library

Prerequisites / Account

First of all, you need an account to use transformer.bee. Ask info@hochfrequenz.de or ping @JoschaMetze on GitHub to get one.

You can check if your account is working by logging into our stage environment.

Using the client

Install it from nuget TransformerBeeClient Nuget Package:

dotnet add package TransformerBeeClient

Authentication

You need to provide something that implements ITransformerBeeAuthenticator to the TransformerBeeClient.

No Authentication

If you're hosting transformer.bee in the same network or your localhost and there is no authentication, you can use the NoAuthenticator.

using TransformerBeeClient;
var myAuthenticator = new NoAuthenticationProvider();

OAuth2 Client and Secret

If, which is more likely, Hochfrequenz provided you with a client Id and secret, you can use the ClientIdClientSecretAuthenticator class like this:

using TransformerBeeClient;
var myAuthenticator = new ClientIdClientSecretAuthenticationProvider("YOUR_CLIENT_ID", "YOUR_CLIENT_SECRET");

Use with ASP.NET Core

This library is thought to be primarily used in ASP.NET Core applications. That's why it assumes that you have an IHttpClientFactory available in your dependency injection container. See the ExampleAspNetCoreApplication/Program.cs for a minimal working example.

Use without ASP.NET Core

If you're not using ASP.NET Core, you can still use this library but setting up th IHttpClientFactory comes with a bit of boilerplate. See the MweWithoutAspNetTest.cs for a minimal working example.

Development

Integration Tests

To run the integration test login to your docker to access the transformer.bee image.

docker login ghcr.io -u YOUR_GITHUB_USERNAME

then paste your PAT similarly to described in the integration test CI pipeline

Release (CI/CD)

To release a new version of this library, create a new release in GitHub. Make sure its tag starts with v and the version number, e.g. v1.2.3. Tags without a release wont trigger the release workflow; This enforces that you have to write a changelog before releasing. Releases are not restricted to the main branch but we prefer them to happen there.

About

A C#/.NET client to communicate with the edifact-bo4e-converter aka transformer.bee

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributo 3723 rs 4

  •  
  •  
  •  
  •  

Languages

0