Luraph.API 2.0.0

The ID prefix of this package has been reserved for one of the owners of this package by NuGet.org. Prefix Reserved
dotnet add package Luraph.API --version 2.0.0
NuGet\Install-Package Luraph.API -Version 2.0.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="Luraph.API" Version="2.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Luraph.API --version 2.0.0
#r "nuget: Luraph.API, 2.0.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.
// Install Luraph.API as a Cake Addin
#addin nuget:?package=Luraph.API&version=2.0.0

// Install Luraph.API as a Cake Tool
#tool nuget:?package=Luraph.API&version=2.0.0

luraph-dotnet

Version Downloads Build Status License

This repository hosts the official SDK for interacting with the Luraph API from .NET environments.

Luraph API access is only available for accounts under certain plans. For more information, please check out the pricing plans on the Luraph website.

Installation

See more information on the NuGet Gallery Page.

Installation via .NET CLI:

dotnet add package Luraph.API

Installation via Package Manager Console:

Install-Package Luraph.API

Usage

The official Luraph API documentation contains the most up-to-date and complete information and instructions for integrating with the Luraph API.

Coming soon! See the test file for an example integration.

Documentation

The official Luraph API documentation contains the most up-to-date and complete information and instructions for integrating with the Luraph API.

class LuraphAPI

new LuraphAPI(string apiKey)

Description: Creates an instance of the SDK.

Parameters:

  • apiKey - API key to authenticate your requests. You can fetch your API key from your account page.

Returns: LuraphAPI


GetNodes()

Description: Obtains a list of available obfuscation nodes.

Parameters: None!

Returns: NodesResponse


CreateNewJob(string node, string script, string fileName, Dictionary<string, object> options, bool useTokens = false, bool enforceSettings = false)

Description: Queues a new obfuscation task.

Parameters:

  • node: The node to assign the obfuscation job to.
  • script: The script to be obfuscated.
  • fileName: A file name to associate with this script. The maximum file name is 255 characters.
  • options: An object containing keys that represent the option identifiers, and values that represent the desired settings. Unless enforceSettings is set to false, all options supported by the node must have a value specified, else the endpoint will error.
  • useTokens - A boolean on whether you'd like to use tokens regardless of your active subscription.
  • enforceSettings - A boolean on whether you'd like the options field to require every option requested by the server to be present with a valid value. If this is false, your integration will not break when invalid options are provided; however, updates that change Luraph's options will result in your integration using default settings when invalid values are specified. By default, this is set to true.

Returns: CreateJobResponse


GetJobStatus(string jobId)

Description: This endpoint does not return until the referenced obfuscation job is complete. The maximum timeout is 60 seconds, and this endpoint can be called a maximum of 3 times per job.

Parameters:

  • jobId - The job ID of the obfuscation to wait for.

Returns: ObfuscateStatusResponse


DownloadResult(string jobId)

Description: Downloads the resulting file associated with an obfuscation job.

Parameters:

  • jobId - The job ID of the obfuscation to download.

Returns: ObfuscateDownloadResponse


struct LuraphOption

Fields:

  • string Name - The human readable name associated with an option.
  • string Description - The markdown formatted description for an option.
  • LuraphOptionTier Tier - Required tier to access the option.
  • LuraphOptionType Type - The type of input requested for the option.
  • bool Required - If creating a user interface to integrate with Luraph, settings that contain a value of true for this field should be explicitly set by the user, since they have a high chance of causing incorrect output when not set properly.
  • string[] Choices - An array of acceptable option values when type == DROPDOWN.
  • Dictionary<string, object[]>? dependencies - An array of required prerequisite values before this setting can be changed from the default value.

struct LuraphNode

Fields:

  • double CpuUsage - The current CPU usage of the node.
  • Dictionary<string, LuraphOption> Options - An object with option identifiers as keys and LuraphOption as values.

struct LuraphError

Fields:

  • string? Param - The parameter associated with the cause of the error.
  • string Message - A human readable error message.

struct NodesResponse

Fields:

  • string? RecommendedId - The most suitable node to perform an obfuscation based on current service load and other possible factors.
  • Dictionary<string, LuraphNode> Nodes - A list of all available nodes to submit obfuscation jobs to.

struct CreateJobResponse

Fields:

  • string JobId - A unique identifier for the queued obfuscation job.

struct ObfuscateStatusResponse

Fields:

  • bool Success - A boolean indicating whether the job was successful.
  • string? Error - An error message if the job failed, or null if the job succeeded.

struct ObfuscateDownloadResponse

Fields:

  • string FileName - A sanitized version of the initial filename, including a suffix to differentiate it from the original filename.
  • Stream Data - A stream containing the obfuscated script.

class LuraphException : Exception

Fields:

  • bool IsHttpError - Whether the exception was caused by an unhandled error.
  • Errors - An array of LuraphError.
  • Message - A human readable collection of error messages returned by a request.

enum LuraphOptionTier

Values:

  • CUSTOMER_ONLY - All customers can access this option.
  • PREMIUM_ONLY - Only customers on a plan with premium features can access this option.
  • ADMIN_ONLY - Only administrators can access this option.

enum LuraphOptionType

Values:

  • CHECKBOX - Expects a boolean value.
  • DROPDOWN - Expects a value contained in the option choices.
  • TEXT - Expects any textual imput.

Product Compatible and additional computed target framework versions.
.NET net7.0 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net7.0

    • No dependencies.

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
2.0.0 92 3/29/2024
1.0.3 94 3/29/2024
1.0.2 101 2/2/2024
1.0.1 69 2/2/2024
1.0.0 71 2/2/2024