Enter this into terminal in your project directory:
dotnet add package OutlineManager
- Get your API Management URL from your Outline Server:
sudo cat /opt/outline/access.txt
- Initialize the server in your C# project
private static string apiUrl = "your URL from Outline Server";
public static OutlineManager server1 = new OutlineManager(apiUrl);
Use method .GetKeys()
to get list of Outline Keys in the List<OutlineKey>
:
//returns List<OutlineKey>
var keys = outline.GetKeys();
You can change name of key by KeyId with the method .RenameKey()
.
Parameters:
- id - ID of the Key
- name - new name for this key
Example:
// return true, if operation was successful
var status = outline.RenameKey(0, "Lance's key");
If your Outline Server's traffic not unlimited, you can adjust data limits with the method .AddDataLimit()
.
Parameters:
- id - ID of the Key in Outline
- limitBytes - Your new limit in bytes
Example:
// return true, if operation was successful
var status = outline.AddDataLimit(0, 0); // if limit in bytes = 0, the key usage is suspended
Also you can remove limit with method outline.DeleteDataLimit(0)
with id parameter
You can create new key for your friend or family with method .CreateKey()
.
// returns key info in OutlineKey
var status = outline.CreateKey(0, 0);
Also you can delete key with method outline.DeleteKey(0)
with id parameter, if this key leaked or useless
You can get list of keys with transferred data in bytes with method .GetTransferredData()
.
// return List<TransferredData>
var transferredData = outline.GetTransferredData();
DonationAlerts
QIWI
YooMoney - 4100115740796249
Sberbank - 4817 7602 1736 1942 (Kirill K.)
Tinkoff - 2200 7007 7308 4180 (Kirill I.)
Papara - 1895931253 (Kirill Corvych) Oldubil - 5388 4105 5265 3265