![]() |
VOOZH | about |
dotnet add package Print3dServer.Core --version 1.0.5
NuGet\Install-Package Print3dServer.Core -Version 1.0.5
<PackageReference Include="Print3dServer.Core" Version="1.0.5" />
<PackageVersion Include="Print3dServer.Core" Version="1.0.5" />Directory.Packages.props
<PackageReference Include="Print3dServer.Core" />Project file
paket add Print3dServer.Core --version 1.0.5
#r "nuget: Print3dServer.Core, 1.0.5"
#:package Print3dServer.Core@1.0.5
#addin nuget:?package=Print3dServer.Core&version=1.0.5Install as a Cake Addin
#tool nuget:?package=Print3dServer.Core&version=1.0.5Install as a Cake Tool
A C# based core library for our 3d Print Server nugets (Moonraker, Repetier Server, OctoPrint and so on)
If you want to support me, you can order over following affilate links (I'll get a small share from your purchase from the corresponding store).
(*) Affiliate link Thank you very much for supporting me!
In order to create your own PrintServerClient, inherit from the base client Print3dServerClient, IPrintServerClient as shown below.
public partial class OctoPrintClient : Print3dServerClient, IPrintServerClient
{
//...
}
The base class holds all needed Methods and Properties needed to communicate with a print server (via REST API and WebSocket).
To query data from your server, simply call send the needed Command. The result will contain the data as JsonString,
which can be accessed over the Result property.
async Task<OctoPrintFiles> GetFilesAsync(string location, string path = "", bool recursive = true)
{
try
{
string files = string.IsNullOrEmpty(path) ? string.Format("files/{0}", location) : string.Format("files/{0}/{1}", location, path);
Dictionary<string, string> urlSegments = new()
{
//get all files & folders
{ "recursive", recursive ? "true" : "false" }
};
string targetUri = $"{OctoPrintCommands.Api}";
IRestApiRequestRespone result = await SendRestApiRequestAsync(
requestTargetUri: targetUri,
method: Method.Get,
command: files,
jsonObject: null,
authHeaders: AuthHeaders,
urlSegments: urlSegments,
cts: default
)
.ConfigureAwait(false);
OctoPrintFiles list = JsonConvert.DeserializeObject<OctoPrintFiles>(result.Result);
if (list != null)
{
FreeDiskSpace = list.Free;
TotalDiskSpace = list.Total;
}
return list;
}
catch (Exception exc)
{
OnError(new UnhandledExceptionEventArgs(exc, false));
return new OctoPrintFiles();
}
}
Each print server uses a different time base for PrintDuration, StartTime and EndTime.
| Property | Core | Moonraker | OctoPrint | Repetier Server |
|---|---|---|---|---|
PrintDuration |
double? (UNIX Hours) |
double? (UNIX Hours) |
tbd | double? (Seconds) |
Modified |
double? (UNIX DT) |
double? (UNIX DT) |
tbd | double? (Seconds) |
Created |
double? (UNIX DT) |
double? (UNIX DT) |
tbd | long? (Seconds) |
Available Converters for XamlBindings:
https://github.com/AndreasReitberger/SharedMauiCoreLibrary/tree/main/src/SharedMauiCoreLibrary/Converters
Or for code behind, use TimeBaseConvertHelper.
[ObservableProperty]
double printTime;
partial void OnPrintTimeChanged(double value)
{
PrintTimeGeneralized = TimeBaseConvertHelper.FromUnixDoubleHours(value);
}
[ObservableProperty]
TimeSpan? printTimeGeneralized;
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 net5.0 was computed. net5.0-windows net5.0-windows was computed. net6.0 net6.0 was computed. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 was computed. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 is compatible. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 is compatible. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 is compatible. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
| .NET Core | netcoreapp3.0 netcoreapp3.0 was computed. netcoreapp3.1 netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.1 netstandard2.1 is compatible. |
| MonoAndroid | monoandroid monoandroid was computed. |
| MonoMac | monomac monomac was computed. |
| MonoTouch | monotouch monotouch was computed. |
| Tizen | tizen60 tizen60 was computed. |
| Xamarin.iOS | xamarinios xamarinios was computed. |
| Xamarin.Mac | xamarinmac xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos xamarinwatchos was computed. |
Showing the top 3 NuGet packages that depend on Print3dServer.Core:
| Package | Downloads |
|---|---|
|
OctoPrintSharpApi
A simple Rest-API-Client for interacting with a OctoPrint instance from any C# project. |
|
|
RepetierServerSharpApi
A simple RestApi for interacting with a Repetier Server Pro instance. |
|
|
MoonrakerSharpWebApi
A simple Rest-API library for interacting with Moonraker web api (used by Fluidd and MainsailOS). |
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.5 | 89 | 6/12/2026 |
| 1.0.4 | 107 | 6/8/2026 |
| 1.0.4-preview4 | 583 | 11/18/2025 |
| 1.0.4-preview3 | 309 | 11/14/2025 |
| 1.0.4-preview2 | 266 | 11/10/2025 |
| 1.0.4-preview1 | 203 | 11/7/2025 |
| 1.0.4-preview | 219 | 11/6/2025 |
| 1.0.3 | 266 | 11/5/2025 |
| 1.0.3-preview | 688 | 1/21/2025 |
| 1.0.2-preview2 | 242 | 6/11/2024 |
| 1.0.1-preview | 241 | 4/22/2024 |
| 1.0.0-preview | 419 | 4/19/2024 |
Check GitHub releases for changelog.