riminder 1.1.0

dotnet add package riminder --version 1.1.0
                    
NuGet\Install-Package riminder -Version 1.1.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="riminder" Version="1.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="riminder" Version="1.1.0" />
                    
Directory.Packages.props
<PackageReference Include="riminder" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add riminder --version 1.1.0
                    
#r "nuget: riminder, 1.1.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.
#:package riminder@1.1.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=riminder&version=1.1.0
                    
Install as a Cake Addin
#tool nuget:?package=riminder&version=1.1.0
                    
Install as a Cake Tool

Riminder Api C#


A c# api client for riminder api.

Instalation with nuget

dotnet add package riminder

Authentification

To authenticate against the api, get your API SECRET KEY from your riminder dashboard: findApiSecret

Then create a new Riminder.Riminder object with this key:

using Riminder;

// Authentification to api
var client = new Riminder("yoursecretkey");

// Finally you can use the api!!.

Api Overview

using System;
using Riminder;

var client = new Riminder("some-key");

// Let's retrieve a profile.
var profile = client.profile.get("source_id", profile_reference:"reference_for_a_profile");

// And print his name !
Console.WriteLine("This profile name is: ");
Console.WriteLine(profile.name");

Errors

If an error occurs while an operation an exception inherited from Riminder.exp.RiminderException is raised.

Api

The mentionned team is the team linked to your secret key.

When both *_id and *_reference arguments are requested only one is required. For example client.filter.get() can take a

  • filter_id (client.filter.get(filter_id: var_filter_id))
  • filter_reference (client.filter.get(filter_reference: var_filter_reference)

and work as well.

All methods return structures which attribute are public and match json keys. Only the data field will be returned. For example: {"code": 200, "message: "All green.", "data": {"name": "Natalie"}} would become

public class ExampleStruct: IResponse
{
    public string name;
}

For details and examples see our documentation.

Filter

  • Get all filters from the team.
Riminder.response.FilterList resp = client.filter.list();
  • Get a specific filter.
Riminder.response.Filter_get resp = client.filter.get(filter_id, filter_reference);

More details about filters are available here

Profile

  • Retrieve the profiles information associated with specified source ids.
    • source_ids (List<string>) is required.
    • date_start and date_end type are long.
    • page, rating and limit type are int.
Riminder.response.ProfileList resp = client.profile.list(source_ids,
 date_start, date_end,
 page, limit , seniority,
 filter_id, filter_reference,
 stage, rating,
 sort_by, order_by);
  • Add a new profile to a source on the platform.
    • source_id and file_path are required
    • file_path is the path to the file to be uploaded.
    • training_metadatas type is response.TrainingMetadatas (response/struct.cs)
Riminder.response.Profile_post resp = client.profile.add(source_id, file_path, profile_reference, timestamp_reception, training_metadatas);
  • Get a specific profile.
Riminder.response.Profile_get resp = client.profile.get(source_id, profile_id, profile_reference);
  • Get attachements of a specific profile.
Riminder.response.ProfileDocument_list resp = client.profile.document.list(source_id, profile_id, profile_reference);
  • Get parsing result of a specific profile.
Riminder.response.ProfileParsing resp = client.profile.parsing.get(source_id, profile_id, profile_reference);
  • Get scoring result of a specific profile.
Riminder.response.ProfileScoringList resp = client.profile.scoring.list(source_id, profile_id, profile_reference);
  • Reveal interpretability result of a specific profile with a specific filter.
Riminder.response.ProfileRevealing resp = client.profile.revealing.get(source_id: source_id, profile_id: profile_id, profile_reference: profile_reference, filter_id: filter_id, filter_reference: filter_reference);
  • Set stage of a specific profile for a specified filter.
    • stage is required.
Riminder.response.ProfileStage resp = client.profile.stage.set(source_id, stage, profile_id, profile_reference, filter_id, filter_reference);
  • Set rating of a specific profile for a spcified filter.
    • rating (int) is required.
Riminder.response.ProfileRating resp = client.profile.stage.set(source_id, rating, profile_id, profile_reference, filter_id, filter_reference);
  • Check if a parsed profile is valid.
    • profile_data (Riminder.response.ProfileJson) is the parsed profile you want to check, can be called "profile_json".
    • training_metadata type is (Riminder.response.TrainingMetadatas)
Riminder.response.ProfileJsonCheck resp = client.json.check(profile_data, training_metadata);
  • Add a parsed profile to a source on the platform.
    • profile_data (Riminder.response.ProfileJson) is the parsed profile you want to add, can be called "profile_json".
    • training_metadata type is (Riminder.response.TrainingMetadatas)
Riminder.response.ProfileJson_post resp = client.json.add(source_id, profile_data, profile_reference, timestamp_reception, training_metadata);

More details about profiles are available here

Sources

  • Get all source from the team.
Riminder.response.SourceList resp = client.source.list();
  • Get a specific filter.
Riminder.response.Source_get resp = client.source.get(source_id);

More details about profiles are available here

Webhooks

Webhooks methods permit you handle webhook events.

  • Check if team's webhook integration is working.
Riminder.response.WebhookCheck resp = client.webhooks.check();
  • Set an handler for a specified webhook event.
    • handler (Riminder.route.Webhook.WebhookHandler) is a delegate of signature: void WebhookHandler(string eventName, response.IWebhookMessage webhook_data)
      • data received by the webhook are store in webhook_data.
      • webhook_data struct follow the same rules as the responses.
      • eventName is type field of the webhook.
client.webhooks.setHandler(Riminder.route.webhook.EventNames.PROFILE_PARSE_SUCCESS, handler);
  • Check if there is an handler for a specified event
client.webhooks.isHandlerPresent(eventName);
  • Remove the handler for an event
client.webhooks.removeHandler(eventName);
  • Start the selected handler depending of the event given.
    • headers is webhook request headers.
    • signatureHeader is webhook request "HTTP-RIMINDER-SIGNATURE" header value.
      • One them is required not both.
client.webhooks.handle(headers, signatureHeader)

Example:

using System;
using Riminder;
using Riminder.route;

public class Example
{
    static void Main()
    {
        var client = new Riminder("apikey");

        // Define an handler
        var handler = delegate (string eventName, response.IWebhookMessage webhook_data) { /* something */};

        // Set the handler for an event
        client.webhooks.setHandler(Webhook.EventNames.PROFILE_PARSE_SUCCESS, handler);

        // Get the header of the request by webhook
        var rcvheaders = fct_that_get_webhook_request();

        // Handle an event
        client.webhooks.handle(headers: rcvheaders);
    }
}

More details about webhooks are available here

Tests

Some tests are available. To run them follow these steps:

  • git clone git@github.com:Riminder/csharp-riminder-api.git
  • cd csharp-riminder-api/riminder.Tests
  • dotnet test

Help and documentation

If you need some more details about the api methods and routes see Riminder API Docs.

If you need further explainations about how the api works see Riminder API Overview

Product 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.  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. 
.NET Core netcoreapp2.1 is compatible.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

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.1.0 945 12/6/2018
1.0.0 979 8/13/2018
0.0.2-alpha 788 8/13/2018
0.0.1-alpha 848 8/9/2018