Reach-TalkyLabs
1.0.0
dotnet add package Reach-TalkyLabs --version 1.0.0
NuGet\Install-Package Reach-TalkyLabs -Version 1.0.0
<PackageReference Include="Reach-TalkyLabs" Version="1.0.0" />
paket add Reach-TalkyLabs --version 1.0.0
#r "nuget: Reach-TalkyLabs, 1.0.0"
// Install Reach-TalkyLabs as a Cake Addin
#addin nuget:?package=Reach-TalkyLabs&version=1.0.0
// Install Reach-TalkyLabs as a Cake Tool
#tool nuget:?package=Reach-TalkyLabs&version=1.0.0
reach-csharp
Reach REST API for .NET
Reach provides a HTTP-based API for sending text messages. Learn more on reach.talkylabs.com.
More documentation for this library can be found here.
Versions
reach-csharp
uses a modified version of Semantic Versioning for all changes. See this document for details.
TLS 1.2 Requirements
It is required to use TLS 1.2 when accessing the REST API. "Upgrade Required" errors indicate that TLS 1.0/1.1 is being used. With .NET, you can enable TLS 1.2 using this setting:
System.Net.ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;
Supported .NET versions
This library supports .NET applications that utilize .NET Framework 3.5+ or .NET Core 1.0+ (.NET Standard 1.4).
Installation
The best and easiest way to add the Reach libraries to your .NET project is to use the NuGet package manager.
With Visual Studio IDE
From within Visual Studio, you can use the NuGet GUI to search for and install the Reach-TalkyLabs NuGet package. Or, as a shortcut, simply type the following command into the Package Manager Console:
Install-Package Reach-TalkyLabs
With .NET Core Command Line Tools
If you are building with the .NET Core command line tools, then you can run the following command from within your project directory:
dotnet add package Reach-TalkyLabs
Sample usage
The examples below show how to have your application send an SMS message using the Reach .NET helper library:
ReachClient.Init("API_USER", "API_KEY");
var message = MessagingItemResource.Send(
src: "+11234567890",
dest: "+10987654321",
body: "Hello World!"
);
Console.WriteLine(message);
Enable debug logging
There are two ways to enable debug logging in the default HTTP client. You can create an environment variable called REACH_TALKYLABS_LOG_LEVEL
and set it to debug
or you can set the LogLevel variable on the client as debug:
ReachClient.SetLogLevel("debug");
Handle exceptions
For an example on how to handle exceptions in this helper library, please see the Reach documentation.
Use a custom HTTP Client
To use a custom HTTP client with this helper library, please see the advanced example of how to do so.
Docker Image
The Dockerfile
present in this repository and its respective talkylabs/reach-csharp
Docker image are used by Talkylabs for testing purposes.
You could use the docker image for building and running tests:
docker build -t reachbuild .
Bash:
docker run -it --rm -v $(pwd):/talkylabs reachbuild
make test
Powershell:
docker run -it --rm -v ${PWD}:/talkylabs reachbuild
make test
Get support
If you've found a bug in the library or would like new features added, go ahead and open issues or pull requests against this repo!
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. 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. |
.NET Core | netcoreapp1.0 was computed. netcoreapp1.1 was computed. netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard1.4 is compatible. netstandard1.5 was computed. netstandard1.6 was computed. netstandard2.0 is compatible. netstandard2.1 was computed. |
.NET Framework | net35 is compatible. net40 was computed. net403 was computed. net45 was computed. net451 is compatible. net452 was computed. net46 was computed. net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen30 was computed. tizen40 was computed. tizen60 was computed. |
Universal Windows Platform | uap was computed. uap10.0 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETFramework 3.5
- JWT (>= 1.3.4)
- Newtonsoft.Json (>= 13.0.1)
-
.NETFramework 4.5.1
- Microsoft.IdentityModel.Tokens (>= 5.1.2)
- Newtonsoft.Json (>= 13.0.1)
- System.IdentityModel.Tokens.Jwt (>= 5.1.2)
-
.NETStandard 1.4
- Microsoft.IdentityModel.Tokens (>= 5.1.2)
- NETStandard.Library (>= 1.6.1)
- Newtonsoft.Json (>= 13.0.1)
- System.Collections.Specialized (>= 4.3.0)
- System.IdentityModel.Tokens.Jwt (>= 5.1.2)
-
.NETStandard 2.0
- Microsoft.IdentityModel.Tokens (>= 6.19.0)
- Newtonsoft.Json (>= 13.0.1)
- System.Collections.Specialized (>= 4.3.0)
- System.IdentityModel.Tokens.Jwt (>= 6.19.0)
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 | 106 | 9/23/2023 |