{"id":20382706,"url":"https://github.com/autodesk-forge/forge-bim360search","last_synced_at":"2025-07-28T16:10:38.903Z","repository":{"id":38048480,"uuid":"207398541","full_name":"Autodesk-Forge/forge-bim360search","owner":"Autodesk-Forge","description":"Search on BIM 360 metadata indexed into Elasticsearch","archived":false,"fork":false,"pushed_at":"2023-03-04T01:14:10.000Z","size":4814,"stargazers_count":12,"open_issues_count":2,"forks_count":9,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-04-12T08:54:16.843Z","etag":null,"topics":["autodesk-bim360","autodesk-data-managemnt","autodesk-webhooks","elasticsearch","mongodb"],"latest_commit_sha":null,"homepage":"http://bim360search.autodesk.io","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Autodesk-Forge.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-09-09T20:28:54.000Z","updated_at":"2024-02-06T14:47:52.000Z","dependencies_parsed_at":"2025-04-12T08:54:17.976Z","dependency_job_id":"60e19d41-4584-43b3-84e1-acb143ebc0a7","html_url":"https://github.com/Autodesk-Forge/forge-bim360search","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Autodesk-Forge/forge-bim360search","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Autodesk-Forge%2Fforge-bim360search","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Autodesk-Forge%2Fforge-bim360search/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Autodesk-Forge%2Fforge-bim360search/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Autodesk-Forge%2Fforge-bim360search/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Autodesk-Forge","download_url":"https://codeload.github.com/Autodesk-Forge/forge-bim360search/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Autodesk-Forge%2Fforge-bim360search/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267544453,"owners_count":24104766,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-28T02:00:09.689Z","response_time":68,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["autodesk-bim360","autodesk-data-managemnt","autodesk-webhooks","elasticsearch","mongodb"],"created_at":"2024-11-15T02:18:45.121Z","updated_at":"2025-07-28T16:10:38.815Z","avatar_url":"https://github.com/Autodesk-Forge.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# forge-bim360search\n\n![Platforms](https://img.shields.io/badge/platform-Windows|MacOS-lightgray.svg)\n![.NET](https://img.shields.io/badge/.NET%20Core-2.1-blue.svg)\n[![License](http://img.shields.io/:license-MIT-blue.svg)](http://opensource.org/licenses/MIT)\n\n[![oAuth2](https://img.shields.io/badge/oAuth2-v1-green.svg)](http://developer.autodesk.com/)\n[![Data-Management](https://img.shields.io/badge/Data%20Management-v2-green.svg)](http://developer.autodesk.com/)\n[![Webhook](https://img.shields.io/badge/Webhook-v1-green.svg)](http://developer.autodesk.com/)\n\n[![Amazon Elastic Search](https://img.shields.io/badge/Amazon%20Elasticsearch-7.1-orange.svg)](https://aws.amazon.com/elasticsearch-service/)\n[![MongoDB](https://img.shields.io/badge/MongoDB%20Atlas-4-darkgreen.svg)](https://aws.amazon.com/elasticsearch-service/)\n\n![Advanced](https://img.shields.io/badge/Level-Advanced-red.svg)\n\n# Description\n\nDemonstrate how to index metadata into a Elasticsearch database ([AWS Service](https://aws.amazon.com/elasticsearch-service/)) and search on it. This sample recursively iterate through all projects of the selected BIM 360 Account (Hub), then into the `Project Files` folder, then subfolders, then the last version of an item, get all the metadata and send to Elasticsearch as a text (not JSON). When a new file is uploaded, a webhook triggers and update the index. Once the index is done, one can search and redirect to the BIM 360 file.\n\n## Thumbnail\n\n![](thumbnail.gif)\n\n# Setup\n\n## Prerequisites\n\n1. **Forge Account**: Learn how to create a Forge Account, activate subscription and create an app at [this tutorial](http://learnforge.autodesk.io/#/account/). \n2. **Visual Studio**: Either Community (Windows) or Code (Windows, MacOS).\n3. **.NET Core** basic knowledge with C#\n4. **ngrok**: Routing tool, [download here](https://ngrok.com/)\n5. **MongoDB**: noSQL database, [learn more](https://www.mongodb.com/). Or use a online version via [mLab](https://mlab.com/) (this is used on this sample)\n6. **AWS Account** with **Elasticsearch**: create or use your AWS Account, [learn more](https://aws.amazon.com/elasticsearch-service/).\n\n## Running locally\n\nClone this project or download it. It's recommended to install [GitHub desktop](https://desktop.github.com/). To clone it via command line, use the following (**Terminal** on MacOSX/Linux, **Git Shell** on Windows):\n\n    git clone https://github.com/autodesk-forge/forge-bim360search\n\n**Amazon Elasticsearch**\n\nCreate or use your AWS Account. Go to [Elasticseach](https://console.aws.amazon.com/es/home) dashboard and **Create new domain**. \n\n- Step 1: you may consider using `Development and testing`:`Development and testing`. \n- Step 2: type your`Elasticsearch domain name`. Other settings as default or adjust as needed.\n- Step 3: depending on your `Network configuration`, or select `Public access`. Select the appropriate `Access policy`, this sample uses **Allow or deny access to one or more IAM users**. Select the appropriate user. This step requires a IAM user.\n- Step 4: review and confirm.\n\nThe creating may take a few minutes, after that take note of the `Endpoint`. \n    \n**MongoDB**\n\n[MongoDB](https://www.mongodb.com) is a no-SQL database based on \"documents\", which stores JSON-like data. For testing purpouses, you can either use local or live. For cloud environment, try [MongoDB Atlas](https://www.mongodb.com/cloud/atlas) (offers a free tier). With MongoDB Atlas you can set up an account for free and create clustered instances, intructions:\n\n1. Create a account on MongoDB Atlas.\n2. Under \"Collections\", create a new database (e.g. named `bim360search`) with a collection (e.g. named `users`).\n3. Under \"Command Line Tools\", whitelist the IP address to access the database, [see this tutorial](https://docs.atlas.mongodb.com/security-whitelist/). If the sample is running on Heroku, you'll need to open to all (IP `0.0.0.0/0`). Create a new user to access the database. \n\nAt this point the connection string should be in the form of `mongodb+srv://\u003cusername\u003e:\u003cpassword\u003e@clusterX-a1b2c4.mongodb.net/inventor2revit?retryWrites=true`. [Learn more here](https://docs.mongodb.com/manual/reference/connection-string/)\n\nThere are several tools to view your database, [Robo 3T](https://robomongo.org/) (formerly Robomongo) is a free lightweight GUI that can be used. When it opens, follow instructions [here](https://www.datduh.com/blog/2017/7/26/how-to-connect-to-mongodb-atlas-using-robo-3t-robomongo) to connect to MongoDB Atlas.\n\n**Visual Studio** (Windows):\n\nRight-click on the project, then go to **Debug**. Adjust the settings as shown below. For environment variable, define the following:\n\n- ASPNETCORE_ENVIRONMENT: `Development`\n- FORGE\\_CLIENT_ID: `your id here`\n- FORGE\\_CLIENT_SECRET: `your secret here`\n- FORGE\\_CALLBACK\\_URL: `http://localhost:3000/api/forge/callback/oauth`\n- FORGE\\_WEBHOOK\\_URL: `http://YOUR HOST OR NGROK ADDRESS`\n- FORGE\\_PARALLEL\\_JOBS: `Number of parallels jobs to get metadata, this affects the memory usage`\n- OAUTH\\_DATABASE: `mongodb+srv://\u003cusername\u003e:\u003cpassword\u003e@clusterX-a1b2c4.mongodb.net/bim360search?retryWrites=true`\n- ELASTIC\\_SEARCH\\_SERVER: `https://yourSearchEndpoint.region.es.amazonaws.com`\n- AWS\\_REGION: `where the Elastic Search is running, e.g. us-east-1`\n- AWS\\_ACCESS_KEY: `your AWS access key here`\n- AWS\\_SECRET_KEY: `your AWS secret key here`\n\n![](forgeSample/wwwroot/img/readme/visual_studio_settings.png) \n\n**Visual Sutdio Code** (Windows, MacOS):\n\nOpen the folder, at the bottom-right, select **Yes** and **Restore**. This restores the packages (e.g. Autodesk.Forge) and creates the launch.json file. See *Tips \u0026 Tricks* for .NET Core on MacOS.\n\n![](forgeSample/wwwroot/img/readme/visual_code_restore.png)\n\nAt the `.vscode\\launch.json`, find the env vars and add your Forge Client ID, Secret and callback URL. Also define the `ASPNETCORE_URLS` variable. The end result should be as shown below:\n\n```json\n\"env\": {\n    \"ASPNETCORE_ENVIRONMENT\": \"Development\",\n    \"ASPNETCORE_URLS\": \"http://localhost:3000\",\n    \"FORGE_CLIENT_ID\": \"your id here\",\n    \"FORGE_CLIENT_SECRET\": \"your secret here\",\n    \"FORGE_CALLBACK_URL\": \"http://localhost:3000/api/forge/callback/oauth\",\n    \"FORGE_WEBHOOK_URL\": \"http://YOUR HOST OR NGROK ADDRESS\",\n    \"FORGE_PARALLEL_JOBS\": \"20\",\n    \"OAUTH_DATABASE\": \"mongodb+srv://\u003cusername\u003e:\u003cpassword\u003e@clusterX-a1b2c4.mongodb.net/bim360search?retryWrites=true\",\n    \"ELASTIC_SEARCH_SERVER\": \"https://search-yourElasticSearch.region.es.amazonaws.com\",\n    \"AWS_REGION\": \"where the Elastic Search is running, e.g. us-east-1\",\n    \"AWS_ACCESS_KEY\": \"your AWS access key here\",\n    \"AWS_SECRET_KEY\": \"your AWS secret key here\"\n},\n```\n\nOpen `http://localhost:3000` to start the app. Select **Index my BIM 360 Account** before using (this process may take a while). Check the `http://localhost:3000/dashboard` to see the jobs running (Hangfire dashboard).\n\n## Deployment\n\n\u003e Due to memory usage, it's likely that this sample will **crash** on Heroku free \u0026 hobby tier (limited to 512Mb of memory). It may work if drawing do not have much metadata.\n\nTo deploy this application to Heroku, the **Callback URL** for Forge must use your `.herokuapp.com` address. After clicking on the button below, at the Heroku Create New App page, set your Client ID, Secret and Callback URL for Forge.\n\n[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)\n\n\n# Further Reading\n\nDocumentation:\n\n- [BIM 360 API](https://developer.autodesk.com/en/docs/bim360/v1/overview/) and [App Provisioning](https://forge.autodesk.com/blog/bim-360-docs-provisioning-forge-apps)\n- [Data Management API](https://developer.autodesk.com/en/docs/data/v2/overview/)\n- [Webhook](https://forge.autodesk.com/en/docs/webhooks/v1)\n\nOther APIs:\n\n- [Hangfire](https://www.hangfire.io/) queueing library for .NET\n- [MongoDB for C#](https://docs.mongodb.com/ecosystem/drivers/csharp/) driver\n- [Mongo Altas](https://www.mongodb.com/cloud/atlas) Database-as-a-Service for MongoDB\n\n\n### Tips \u0026 Tricks\n\nThis sample uses .NET Core and works fine on both Windows and MacOS, see [this tutorial for MacOS](https://github.com/augustogoncalves/dotnetcoreheroku).\n\n### Troubleshooting\n\n1. **Cannot see my BIM 360 projects**: Make sure to provision the Forge App Client ID within the BIM 360 Account, [learn more here](https://forge.autodesk.com/blog/bim-360-docs-provisioning-forge-apps). This requires the Account Admin permission.\n\n2. **error setting certificate verify locations** error: may happen on Windows, use the following: `git config --global http.sslverify \"false\"`\n\n## License\n\nThis sample is licensed under the terms of the [MIT License](http://opensource.org/licenses/MIT). Please see the [LICENSE](LICENSE) file for full details.\n\n## Written by\n\nAugusto Goncalves [@augustomaia](https://twitter.com/augustomaia), [Forge Partner Development](http://forge.autodesk.com)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fautodesk-forge%2Fforge-bim360search","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fautodesk-forge%2Fforge-bim360search","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fautodesk-forge%2Fforge-bim360search/lists"}