AutoDesk API for List of Fusion 360 Files - autodesk-forge

Using the Autodesk Forge Auth API, I can get a bearer token for my app and I can get the ID of the user. I want to get a list of Fusion 360 files that the user owns. How can I do this? It seems like it would be part of the Data Management API, but I can't find it.
I use the forge api for data management to ask for the hubs for a user. I get a response that has a 200 status, but there is nothing in the response - no data and nothing like what is in the example.
Any ideals as to how to get those files?

If the GET Hubs response is empty, most likely that user don't have any hub. Is there any warning or error on the response body?
And this tutorial should help you get started, or try this live sample (source in .NET)

Related

Forge ARKit Get Unity Status 501 Not Implemented

I was trying the Forge ARKit API (https://app.swaggerhub.com/apis/cyrillef/forge-ar_kit/2.0.0#/info) and I was able to load a revit model in Unity through the asset (http://forgetoolkit.com/#/unityPackage). Then I saw that the API has an url to download a model as UnityPackage (https://app.swaggerhub.com/apis/cyrillef/forge-ar_kit/2.0.0#/ARKit/get_unity), but unfortunately I get a 501 status Not Implemented.
I'm doing a GET request to "https://developer-api-beta.autodesk.io/modelderivative/v2/arkit/{{urn}}/unity" with the Authorization token and the same urn base64url I used for the other urls.

Error in Querying BIM 360 project attribute

I'm currently using an AWS lambda function to automate the creation of a BIM 360 project by using multiple BIM 360 API endpoints.
It's been working fine, but I've just noticed that it stopped working, failing to access GET projects/:project_id endpoint. My code accesses each BIM 360 project's job_number attribute to filter duplicated projects by using job_number. And the code is failing at getting the response of the GET projects/:project_id request.
Has there been any change in the API recently? Thank you in advance.
from the latest reply, it looks you hit rate limit. If am correct, the response error code is 429. Each category API has restriction of rate limit. e.g. This is rate limit of Data Management API
https://forge.autodesk.com/en/docs/data/v2/developers_guide/rate-limiting/dm-rate-limits/
And this is BIM360 API:
https://forge.autodesk.com/en/docs/bim360/v1/overview/rate-limits/
So, you will need to set some delays of each call to meet the rate, or use some async management methods such as async-pool in Node.js to control the calls rate or every minute.

Autodesk Forge 403 When Trying to Retrieve Issues

I'm following the Issue Retrieval tutorial: https://forge.autodesk.com/en/docs/bim360/v1/tutorials/retrieve-issues/
After getting a token I'm able to retrieve my hubs, then my projects, but when it comes time to retrieve issues in a project I am getting a 403 forbidden.
Trying to retrieve issues with the following URL:
https://developer.api.autodesk.com/issues/v1/containers/[issue_container_id]/issues
where [issue_container_id] is retrieved from data[0].relationships.issues.data.id from the https://developer.api.autodesk.com/project/v1/hubs/[hub_id]/projects response
My auth token scope is data:read and I've even tried with data:read and data:write since I was initially trying to write an issue, but also got a 403.
My Forge app has access to BIM 360 API, Data Management API, and WebHook API.
My BIM 360 integration gives the Forge app acess to BIM 360 Account Admin and Document management.
According to our engineering team, BIM360 Issue APIs support three-legged token only currently. Apologizing for the confusion, the tutorial will be updated soon.

Can model derivative get all the information from BIM?

I'm very new to forge and revit. I've been trying to see if I can get all the information from Revit / BIM file programmatically. I know I might be able to get it with DB link or excel, but export to excel seems an extract steps.
Then I found out Forge, I was assuming Model Derivative APIs will did the job for you, basically upload the files to bucket and click on the models to select object, let's say a floor, I should be able to make API calls with all the information about that floor. However, when I play around with Forge, it seems like not every information is in the properties. Is that correct? Or I just didn't implement it correctly?
Thanks for your answer.
It is possible to get all the information regarding properties of any/all object(s).
First you need to get the URN of the version of the file, get the metadata from this API:
https://developer.autodesk.com/en/docs/model-derivative/v2/reference/http/urn-metadata-GET/
Use the next 2 APIs in the above link to get properties of any/all object(s).
In case you don't know how to get URN:
The way you get URN is from forge Data Management Api, you can list Hubs > Projects > Folders > Items > Versions.
This tutorial guides you on the steps.

Record all request uris/methods/response codes for Google Drive Java Client Library

I'm using the google client library to access the Google Drive API. I'd like to custom log all the request URI's, the request method as well as the response codes. Is there a built in mechanism to do this with the google client library?
Ideally, I could use the API as I am now and not have to modify each request but maybe add some sort of interceptor to the Drive object itself where I can record this data on every request that goes through this Drive service.
Any ideas?
Not sure that is exactly what you want but you could modify the log level of the API client in logging.properties
com.google.api.client.level = FINEST