Skip to content

autodesk-platform-services/aps-dotnet-blazor-samples

Repository files navigation

Autodesk Platform Services .NET Blazor Samples

platforms Automation API Revit-2026 .NET C# license


A Blazor Server web application demonstrating how to use Autodesk Platform Services (APS) with .NET 10. The sample showcases three key capabilities powered by the APS Automation API and Data Management API:

  • Create Revit Models – Programmatically create Revit cloud models inside Autodesk Construction Cloud (ACC) projects.
  • Manage Revit Links – Add or remove Revit links between models using a visual link matrix.
  • Create Sheets – Batch-create sheets in Revit cloud models.

The app uses 3-legged OAuth to authenticate users via their Autodesk account, then lets them browse their ACC hubs and projects through a folder explorer, configure automation jobs, and track their real-time status.

thumbnail


⚠️ Disclaimer
This is a vibe-coded sample solution - an exploratory proof-of-concept developed iteratively. It demonstrates patterns and possibilities but may not follow all production-grade practices. This README was generated by GitHub Copilot based on analyzing the actual codebase, ensuring documentation matches implementation.


Usage

  1. Sign in with your Autodesk account via the Sign In button on the home page.
  2. Choose one of the three workflows from the home page cards:
    • Create Revit Models – select a project and target folder, fill in the model configuration, and submit.
    • Manage Revit Links – select a project, build a link matrix between models, and apply it.
    • Create Sheets – select a project and Revit model, define the sheet list, and submit.
  3. Track job progress on the corresponding tracking page; results are updated in real time.
APS.Blazor.Webapp.mp4

Development

Prerequisites


Steps to build and run the sample locally

  1. Clone the repository

    git clone https://github.com/autodesk-platform-services/aps-dotnet-blazor-samples.git
    cd aps-dotnet-blazor-samples
  2. Configure app settings

    Open appsettings.json (or use .NET User Secrets) and fill in your credentials:

    {
      "Forge": {
        "ClientId": "<your-client-id>",
        "ClientSecret": "<your-client-secret>",
        "CallbackUrl": "https://localhost:<port>/api/auth/callback",
        "AutomationActivity": "<your-activity-alias>"
      }
    }

    Using User Secrets (recommended):

    dotnet user-secrets set "Forge:ClientId" "<your-client-id>"
    dotnet user-secrets set "Forge:ClientSecret" "<your-client-secret>"
    dotnet user-secrets set "Forge:CallbackUrl" "https://localhost:<port>/api/auth/callback"
    dotnet user-secrets set "Forge:AutomationActivity" "<your-activity-alias>"
  3. Run the application

    dotnet run

    Navigate to https://localhost:<port> in your browser.


Deployment

When deploying to a hosting environment (e.g. Azure App Service):

  • Set the four Forge:* values as environment variables or application settings.
  • Ensure the Callback URL registered on your APS app matches the deployed URL.
  • Automation API workitems use ngrok-style HTTP callbacks on the /da path — configure any reverse proxy to pass that path through without HTTPS redirection.

Known limitations

  • Job status is stored in-memory; restarting the application clears pending job history.
  • The Automation API activity must already exist and be published before running the sample.

Additional resources


License

This sample is licensed under the terms of the MIT License. Please see the LICENSE file for full details.

About

A sample .NET Blazor web application demonstrating how to use Autodesk Platform Services for AEC

Topics

Resources

License

Stars

Watchers

Forks