• Joined on 2026-06-30

PolarisLib (1.8.13)

Published 2026-06-30 18:55:34 +00:00 by neto

Installation

dotnet nuget add source --name neto --username your_username --password your_token https://gitea.jbsn.com.br/api/packages/neto/nuget/index.json
dotnet add package --source neto --version 1.8.13 PolarisLib

About this package

No description

English | Portuguese

Polaris

What is it?

Polaris is a user and application management API designed to perform login through MFA, or Firebase.

How does it work?

The API provides the following groups of routes:

  • /Application

    • Allows managing applications.
  • /Authentication

    • Allows performing authentication (MFA or Firebase).

Getting Started

Generate package using the command:

dotnet pack --configuration Release --output .

push the package using the command:

dotnet nuget push "PolarisLib.1.8.13.nupkg" --source "gitea"

create in your project the file nuget.config:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
    <packageSources>
        <add key="gitea" value="https://gitea.jbsn.com.br/api/packages/neto/nuget/index.json" />
    </packageSources>
    <packageSourceCredentials>
        <gitea>
            <add key="Username" value="neto" />
            <add key="ClearTextPassword" value="1891eea97d10b1ae3f038578205c856affdcc2d0" />
        </gitea>
    </packageSourceCredentials>
</configuration>

after this, execute the command:

dotnet add package PolarisLib

How to use ?

In the file program.cs add the code:

builder.Services.AddPolarisAuthorization(builder.Configuration);

To configure authentication, put the options in appSettings.json

Minimum configuration required

"Polaris": {
  "Key": "a6c9fe83-dcde-4495-98cc-e218a22924a2"
}

Complete configuration

"Polaris": {
  "Key": "a6c9fe83-dcde-4495-98cc-e218a22924a2",
  "GenerateController": true,
  "PrefixRouter": "api",
  "Authentication": {
    "OnGenerateCode": {
      "CreateUserAutomatic": false
    },
    "GoogleOAuth2": {
        "ClientId": "a8b7857a-492e-45da-adad-43ac65acbec1"
    },
    "Firebase" : {
      "AppId": "da1c3f06-0e5f-44c6-a38a-5ec6b02a0094",
      "JsonCredencials": "f7dfa792-815c-4bf8-aae5-db0f2cdebfcc"
    }
  },
  "User": {
    "OnCreate": {
      "Roles": [
        "ROLE1", 
        "ROLE2"
      ]
    }
  }
}

Dependencies

ID Version Target Framework
Microsoft.AspNetCore.Authentication.JwtBearer 10.0.0 net10.0
Microsoft.AspNetCore.Routing 2.3.0 net10.0
Details
NuGet
2026-06-30 18:55:34 +00:00
6
JBSN
26 KiB
Assets (2)
Versions (1) View all
1.8.13 2026-06-30