{"id":17021217,"url":"https://github.com/cyrillef/propertyserver","last_synced_at":"2025-04-23T00:48:07.550Z","repository":{"id":70293590,"uuid":"128440597","full_name":"cyrillef/propertyServer","owner":"cyrillef","description":"Forge Model PropertyServer to workaround the Model Derivative API limitations","archived":false,"fork":false,"pushed_at":"2018-10-16T12:42:43.000Z","size":88,"stargazers_count":5,"open_issues_count":0,"forks_count":9,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-23T00:48:00.857Z","etag":null,"topics":["autodesk","forge","modelderivative"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/cyrillef.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}},"created_at":"2018-04-06T18:42:53.000Z","updated_at":"2025-03-11T19:21:07.000Z","dependencies_parsed_at":"2023-02-22T10:45:14.704Z","dependency_job_id":null,"html_url":"https://github.com/cyrillef/propertyServer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyrillef%2FpropertyServer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyrillef%2FpropertyServer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyrillef%2FpropertyServer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cyrillef%2FpropertyServer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cyrillef","download_url":"https://codeload.github.com/cyrillef/propertyServer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250348876,"owners_count":21415910,"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","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","forge","modelderivative"],"created_at":"2024-10-14T07:07:04.686Z","updated_at":"2025-04-23T00:48:07.537Z","avatar_url":"https://github.com/cyrillef.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# propertyServer sample\n\n[![Node.js](https://img.shields.io/badge/Node.js-9.5.0-blue.svg)](https://nodejs.org/)\n[![npm](https://img.shields.io/badge/npm-5.8.0-blue.svg)](https://www.npmjs.com/)\n![Platforms](https://img.shields.io/badge/platform-windows%20%7C%20osx%20%7C%20linux-lightgray.svg)\n[![License](http://img.shields.io/:license-mit-blue.svg)](http://opensource.org/licenses/MIT)\n\n\n*Forge API*:\n[![oAuth2](https://img.shields.io/badge/oAuth2-v1-green.svg)](http://developer-autodesk.github.io/)\n[![Model-Derivative](https://img.shields.io/badge/Model%20Derivative-v2-green.svg)](http://developer-autodesk.github.io/)\n\n\n\u003cb\u003eNote:\u003c/b\u003e For using this sample, you need a valid oAuth credential for accessing resources on Autodesk Forge.\nVisit this [page](https://developer.autodesk.com) for instructions to get on-board.\n\n\n## Description\n\nThe propertyServer server exercises a workaround to the Forge Model Derivative API limitations to [request properties](https://developer.autodesk.com/en/docs/model-derivative/v2/reference/http/urn-metadata-guid-properties-GET/).\nIt also demonstrates how to parse the bubble json.gz property files.\n\nIn order to make use of this sample, you need to register your consumer and secret keys:\n\n* https://developer.autodesk.com \u003e My Apps\n\nThis provides the credentials to supply to the http requests to the Autodesk server endpoints.\n\n\n## Dependencies\n\nThis sample is dependent on the server part on Node.js and couple of Node.js extensions\nwhich would update/install automatically via 'npm':\n\n\n## Setup/Usage Instructions\n\n### Deploy on Heroku\n\n[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)\n\n\n\u003ca name=\"setupSample\"\u003e\u003c/a\u003e\n### Setup\n1. Download and install [Node.js](http://nodejs.org/) (that will install npm as well)\n2. Download this repo anywhere you want (the server will need to write files, so make sure you install in\n   a location where you have write permission, at least the 'tmp', 'data' and '/www/extracted' folders)\n3. Execute 'npm install', this command will download and install the required node modules automatically for you. \u003cbr /\u003e\n   ```\n   npm install\n   ```\n4. Install your credential keys: \u003cbr /\u003e\n   Use system environment variables (This is actually the option you need to use for the tests suite\n   which runs on [Travis-CI](https://travis-ci.org/)). Replace keys placeholder xxx with your own keys.\n\n          * Windows\u003cbr /\u003e\n            ```\n            set FORGE_CLIENT_ID=xxx\n\n            set FORGE_CLIENT_SECRET=xxx\n\t    \n\t    set FORGE_CALLBACK=xxx\n\n            [set PORT=\u003cport\u003e]\n\n\t\t\tnode start.js\n            ```\n          * OSX/Linux\u003cbr /\u003e\n            ```\n            [sudo] [PORT=\u003cport\u003e] FORGE_CLIENT_ID=xxx FORGE_CLIENT_SECRET=xxx FORGE_CALLBACK=xxx node start.js\n            ```\n   \u003cbr /\u003e\n   \u003cb\u003eNote:\u003c/b\u003e the port argument can be omitted and default to port 80. If port 80 is already in use by another\n   application (like Skype, or IIS, or Apache, ...), you can use any other free port such as 8000, 3000, etc...\n   But in the next section you would need to specify the port to use, i.e. http://localhost[:port]/\n\n\n\u003ca name=\"UseOfTheSample\"\u003e\u003c/a\u003e\n### Use of the sample\n\n1. Get resources from your file\u003cbr /\u003e\n  ```\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/load\n  ```\n  Note the server, use a 2 legged definition by default, but you can override the Authorization by adding an header to the request in order to use your own.\n  ```\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/load -H \"Authorization: Bearer ey9f...ks7A\"\n  ```\n2. Verify resources are ready\u003cbr /\u003e\n  ```\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/load/progress\n  ```\n3. Get IDs and ExternalIDs\n  ```\n  # Get the highest ID\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/ids/range\n\n  # Get all externalIDs\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/ids/*\n\n  # Get externalIDs for 1 object with Id == 1789\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/ids/1789\n\n  # Get externalIDs for several objects with Id == 1066, 1515, 1789\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/ids/1066,1515,1789\n\n  # Get externalIDs for group of objects with Id between 1515 and 1531\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/ids/1515-1531\n\n  # Get externalIDs for group of objects with Id between 1515 and 1531 and few other objects with Id == 1066, 1789\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/ids/1066,1515-1531,1789\n\n  ```\n4. Get properties\u003cbr /\u003e\n  ```\n  # Get all properties\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/properties/*\n\n  # Get properties for 1 object with Id == 1789\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/properties/1789\n\n  # Get properties for several objects with Id == 1066, 1515, 1789\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/properties/1066,1515,1789\n\n  # Get properties for group of objects with Id between 1515 and 1531\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/properties/1515-1531\n\n  # Get properties for group of objects with Id between 1515 and 1531 and few other objects with Id == 1066, 1789\n  curl -X GET http://localhost:3000/data/dXJuO...Lm53ZA/properties/1066,1515-1531,1789\n  ```\n  Note you can add the -H \"Accept-Encoding: gzip\" or -H \"Accept-Encoding: deflate\" or -H \"Accept-Encoding: gzip, deflate\" to compress the JSON reply.\n\n4. Free the resources if you do not need it any more\u003cbr /\u003e\n  ```\n  curl -X DELETE http://localhost:3000/data/dXJuO...Lm53ZA\n  ```\n\n\n### BIM360docs and 3legged support\n\nThe only time you need a different token than the one generated and used by the server is when you want to access a database coming from a file stored on BIM360docs / Fusion360. In this case, you need a 3legged token which requires you to log with a user credentials. You can get teh token from your application or get help from this server as long you provisionned your keys on the service.\n\nThis is where you need to define the FORGE_CALLBACK environment variable, and in your browser go to http://localhost:3000/3legged. After the login process, you should see an access_token on the page you can use to load the database resource on the propertyServer.\n\n--------\n\n## License\n\nThis sample is licensed under the terms of the [MIT License](http://opensource.org/licenses/MIT).\nPlease see the [LICENSE](LICENSE) file for full details.\n\n\n## Written by\n\nCyrille Fauvel \u003cbr /\u003e\nForge Partner Development \u003cbr /\u003e\nhttp://developer.autodesk.com/ \u003cbr /\u003e\nhttp://around-the-corner.typepad.com \u003cbr /\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyrillef%2Fpropertyserver","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcyrillef%2Fpropertyserver","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyrillef%2Fpropertyserver/lists"}