MarcWils.Vecozo.VspKoppelingSdk
1.0.0
dotnet add package MarcWils.Vecozo.VspKoppelingSdk --version 1.0.0
NuGet\Install-Package MarcWils.Vecozo.VspKoppelingSdk -Version 1.0.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="MarcWils.Vecozo.VspKoppelingSdk" Version="1.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add MarcWils.Vecozo.VspKoppelingSdk --version 1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: MarcWils.Vecozo.VspKoppelingSdk, 1.0.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install MarcWils.Vecozo.VspKoppelingSdk as a Cake Addin #addin nuget:?package=MarcWils.Vecozo.VspKoppelingSdk&version=1.0.0 // Install MarcWils.Vecozo.VspKoppelingSdk as a Cake Tool #tool nuget:?package=MarcWils.Vecozo.VspKoppelingSdk&version=1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
SDK voor VECOZO VSP-Koppeling API's
VSP-Koppeling berichtuitwisseling REST Push V1 sample
var services = new ServiceCollection();
services.AddHttpClient<BerichtuitwisselingPushClient>(httpClient =>
/*
* Endpoints:
* - TST: https://tst-api.vecozo.nl/tst/berichtenservice/berichten/rest-push/v1/
* - ACC: https://tst-api.vecozo.nl/acc/berichtenservice/berichten/rest-push/v1/
* - PRD: https://api.vecozo.nl/berichtenservice/berichten/rest-push/v1/
* */
httpClient.BaseAddress = new Uri("https://tst-api.vecozo.nl/tst/berichtenservice/berichten/rest-push/v1/")
).ConfigurePrimaryHttpMessageHandler(sp =>
{
var handler = new HttpClientHandler();
// Certicaat inladen van disk, certificate store, KeyVault, o.i.d.
var certificate = new X509Certificate2("path-to-certificate.pfx", "pwd");
handler.ClientCertificates.Add(certificate);
return handler;
});
var sp = services.BuildServiceProvider();
var pushClient = sp.GetRequiredService<BerichtuitwisselingPushClient>();
await pushClient.PostBerichtAsync(new BerichtMetadata
{
Routeringgegevens = new Routeringgegevens
{
Afzender = new Relatie
{
Rol = "Praktijk", // Praktijk, Zorgverlener, Instelling, Zorgverzekeraar, ...
Code = "10000001", // AGB-code, UZOVI, ...
},
Geadresseerden = [
new Relatie {
Rol = "Zorgverzekeraar",
Code = "1000"
}
],
Berichtstroom = new Berichtstroom
{
// Zie berichtuitwisselingsdocumentatie
Berichttype = "Test",
Berichtsubtype = "Test",
Actie = "Indienen",
Berichtversie = 1,
Berichtsubversie = 0
}
},
Referentiegegevens = new Referentiegegevens
{
// Conversatie ID koppelt meerdere berichten logisch aan elkaar.
ConversatieId = Guid.NewGuid(),
// Traceer ID is uniek voor elk bericht. Dit kan later gebruikt worden om de berichtstatus op te halen
// of een retourbestand te correleren.
TraceerId = Guid.NewGuid()
}
},
// Data (payload) is het werkelijk uit te wissel bestand.
new FileParameter(data: new MemoryStream(Encoding.UTF8.GetBytes("Hello world!"))));
VSP-Koppeling berichtuitwisseling REST Pull V1 sample
var services = new ServiceCollection();
services.AddHttpClient<BerichtuitwisselingPullClient>(httpClient =>
/*
* Endpoints:
* - TST: https://tst-api.vecozo.nl/tst/berichtenservice/berichten/rest-pull/v1/
* - ACC: https://tst-api.vecozo.nl/acc/berichtenservice/berichten/rest-pull/v1/
* - PRD: https://api.vecozo.nl/berichtenservice/berichten/rest-pull/v1/
* */
httpClient.BaseAddress = new Uri("https://tst-api.vecozo.nl/tst/berichtenservice/berichten/rest-pull/v1/")
).ConfigurePrimaryHttpMessageHandler(sp =>
{
var handler = new HttpClientHandler();
// Certicaat inladen van disk, certificate store, KeyVault, o.i.d.
var certificate = new X509Certificate2("path-to-certificate.pfx", "pwd");
handler.ClientCertificates.Add(certificate);
return handler;
});
var sp = services.BuildServiceProvider();
var pullClient = sp.GetRequiredService<BerichtuitwisselingPullClient>();
var httpClient = sp.GetRequiredService<HttpClient>();
// Haal de 100 langst gereedstaande berichten op.
// Evt. kan er gerichter gezocht worden via de .ZoekBerichtenAsync() methode.
var berichten = await pullClient.GetBerichtenAsync(limit: 100);
foreach (var bericht in berichten)
{
// bericht bevat alle metadata bij het bericht (berichtstroom, afzender, geadresseerde, e.d.).
// De payload (bestand) dient opgehaald te worden via een aparte call.
var payload = await httpClient.GetStreamAsync(bericht.Basisgegevens.Payload.Url);
// Als de metadata en payload goed opgehaald (en geregistreerd is), dient de ontvangst bevestigd te worden.
// Zo kan de volgende set aan gereedstaande berichten opgehaald worden.
await pullClient.BevestigOntvangstAsync(bericht.Referentiegegevens.TraceerId);
}
VSP-Koppeling berichtstatus REST Pull V2 sample
var services = new ServiceCollection();
services.AddHttpClient<BerichtstatusPullClient>(httpClient =>
/*
* Endpoints:
* - TST: https://tst-api.vecozo.nl/tst/berichtenservice/berichtstatus/rest-pull/v2/
* - ACC: https://tst-api.vecozo.nl/acc/berichtenservice/berichtstatus/rest-pull/v2/
* - PRD: https://api.vecozo.nl/berichtenservice/berichtstatus/rest-pull/v2/
* */
httpClient.BaseAddress = new Uri("https://tst-api.vecozo.nl/tst/berichtenservice/berichtstatus/rest-pull/v2/")
).ConfigurePrimaryHttpMessageHandler(sp =>
{
var handler = new HttpClientHandler();
// Certicaat inladen van disk, certificate store, KeyVault, o.i.d.
var certificate = new X509Certificate2("path-to-certificate.pfx", "pwd");
handler.ClientCertificates.Add(certificate);
return handler;
});
var sp = services.BuildServiceProvider();
var berichtstatusPullClient = sp.GetRequiredService<BerichtstatusPullClient>();
// De berichstatus kan opgehaald worden o.b.v. traceer ID of conversatie ID.
var berichtstatussen = await berichtstatusPullClient.ZoekBerichtstatussenAsync(traceerId: Guid.NewGuid(), null);
// Ook de de berichtstatus van de gekoppelde berichten (bv. retourberichten) worden teruggekoppeld.
// Als het bericht is afgekeurd, worden ook de bijhorende meldingen teruggekoppeld.
Disclaimer
This is no official VECOZO NuGet package.
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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
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.
Version | Downloads | Last updated |
---|---|---|
1.0.0 | 115 | 10/6/2024 |
v1.0.0
- Initial version