![]() |
VOOZH | about |
dotnet add package Autodesk.Forge.DesignAutomation --version 6.0.2
NuGet\Install-Package Autodesk.Forge.DesignAutomation -Version 6.0.2
<PackageReference Include="Autodesk.Forge.DesignAutomation" Version="6.0.2" />
<PackageVersion Include="Autodesk.Forge.DesignAutomation" Version="6.0.2" />Directory.Packages.props
<PackageReference Include="Autodesk.Forge.DesignAutomation" />Project file
paket add Autodesk.Forge.DesignAutomation --version 6.0.2
#r "nuget: Autodesk.Forge.DesignAutomation, 6.0.2"
#:package Autodesk.Forge.DesignAutomation@6.0.2
#addin nuget:?package=Autodesk.Forge.DesignAutomation&version=6.0.2Install as a Cake Addin
#tool nuget:?package=Autodesk.Forge.DesignAutomation&version=6.0.2Install as a Cake Tool
👁 Design-Automation
👁 SDK
👁 .NET
👁 BUILD
👁 nuget
.NET SDK for Design Automation v3 API, for more information, please visit official documentation
For clients with straightforward needs one high level API client is provided in . For clients with more varied needs the following low level API classes are provided: , , , , , , .
The change log for the SDK can be found .
Contributions are welcome! Please open a Pull Request.
Please ask questions on StackOverflow with tag autodesk-designautomation tag. If it turns out that you may have found a bug, please open an issue
To use the API you must instantiate one of the API classes and configure it with the valid forge credentials. You can do this in 2 ways:
There are 2 classes that you can use to configure the API:
Autodesk.Forge.Core.ForgeConfiguration - Allows the configuration of Forge client credentials and alternative authentication service endpoint (default is https://developer.api.autodesk.com/authentication/v2/token)
- Allows the configuration of non-default API endpoint (default is https://developer.api.autodesk.com/da/us-east/).
This SDK integrates with the .netcore configuration system. You can configure the above values via any configuration provider (e.g. appsettings.json or environment variables).
For example to set the Forge credentials you could define the following environment variables:
Forge__ClientId=<your client id>
Forge__ClientSecret=<your client secret>
or the following in your appsettings.json:
{
"Forge": {
"ClientId" : "<your client id>",
"ClientSecret" : "<your client secret>"
}
}
or using environment variables with ForgeAlternativeConfigurationExtensions:
FORGE_CLIENT_ID=<your client id>
FORGE_CLIENT_SECRET=<your client secret>
Starting with version 4.3 you can also configure multiple ClientId/ClientSecret pairs as follows:
{
"Forge": {
"ClientId": "<default clientId>"
"ClientSecret" : "<default clientSecret>"
"Agents": {
"agent1": {
"ClientId": "<clientId of agent1>"
"ClientSecret" : "<clientSecret of agent1>"
},
"agent2": {
"ClientId": "<clientId of agent2>"
"ClientSecret" : "<clientSecret of agent2>"
}
},
...
}
These credentials are used when you create a named DesignAutomationClient via where name should match the name of the agent in configuration.
Please visit Learn Forge tutorial.
First you must add Autodesk.Forge.DesignAutomation services. This is usually done in ConfigureServices(...) method of your Startup class. More information
NOTE: This example assumes that you are building an Asp.Net Core web api or website. If you want to use dependency injection in a console app then follow this example.
using Autodesk.Forge.DesignAutomation;
using Autodesk.Forge.DesignAutomation.Model;
...
public void ConfigureServices(IServiceCollection services)
{
services.AddDesignAutomation(this.Configuration);
}
Then you can use any of the API classes or interfaces in a constructor:
using Autodesk.Forge.DesignAutomation;
...
public class SomeApiController : ControllerBase
{
public SomeApiController(IWorkItemsApi forgeApi)
{
//use forgeApi here
}
using Autodesk.Forge.DesignAutomation;
using System.Net.Http;
using System.Threading.Tasks;
using Autodesk.Forge.Core;
internal class Program
{
public static void Main(string[] args)
{
var service =
new ForgeService(
new HttpClient(
new ForgeHandler(Microsoft.Extensions.Options.Options.Create(new ForgeConfiguration()
{
ClientId = "<your client id>",
ClientSecret = "<your client secret>"
}))
{
InnerHandler = new HttpClientHandler()
})
);
var forgeApi = new WorkItemsApi(service);
}
}
Using Semantic Version scheme following the pattern of x.y.z.:
x: MAJOR version when you make incompatible changes,y: MINOR version when you add functionality in a backwards-compatible manner, andz: PATCH version when you make backwards-compatible bug fixes.Generated with swagger-codegen.
dotnet build Autodesk.Forge.DesignAutomation.sln
dotnet test Autodesk.Forge.DesignAutomation.sln
This sample is licensed under the terms of the Apache License 2.0. Please see the file for full details.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | 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 was computed. 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 was computed. 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. |
Showing the top 2 NuGet packages that depend on Autodesk.Forge.DesignAutomation:
| Package | Downloads |
|---|---|
|
ricaun.Autodesk.Forge.Oss.DesignAutomation
Revit Package ricaun.Autodesk.Forge.Oss.DesignAutomation |
|
|
APSToolkit
The toolkit support imporve process Autodesk Forge Pipeline |
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 6.0.2 | 86,118 | 11/22/2024 |
| 6.0.1 | 29,363 | 8/14/2024 |
| 6.0.0 | 8,717 | 6/22/2024 |
| 5.1.2 | 47,252 | 7/26/2023 |
| 5.1.1 | 10,416 | 1/5/2023 |
| 5.1.0 | 18,282 | 4/21/2022 |
| 5.0.2 | 3,494 | 2/15/2022 |
| 5.0.1 | 654 | 2/15/2022 |
| 5.0.0 | 679 | 2/14/2022 |
| 4.3.1 | 4,435 | 2/9/2022 |
| 4.3.0 | 652 | 2/7/2022 |
| 4.2.0 | 6,490 | 8/20/2021 |
| 4.1.0 | 1,108 | 7/28/2021 |
| 4.0.0 | 2,846 | 5/19/2021 |
| 3.0.6 | 39,431 | 11/10/2020 |
| 3.0.5 | 20,042 | 10/30/2020 |
| 3.0.4 | 724 | 10/30/2020 |
| 3.0.3 | 5,305 | 8/13/2020 |
| 3.0.2 | 24,346 | 4/1/2020 |
| 3.0.1 | 1,847 | 12/31/2019 |
For full release notes see https://github.com/Autodesk-Forge/forge-api-dotnet-core/blob/master/CHANGELOG.md