Publish current Maya scene
1 1

2 posts in this topic

Hi @Jamie Kenyon, the easier way would be to use the ftrack-python-api directly rather than the connector ones, which really have not been built for this purpose, that said though, this is some basic code you can start playing with :

please also note, connector is built on top of the legacy api and not the latest ftrack-python-api , hence you might have to do some dance to convert data between one another.
Is not hard, just inefficient.

from ftrack_connect_maya.connector.mayaassets import SceneAsset
from ftrack_connect.connector.base import FTAssetObject

scene_asset = SceneAsset()

iAObj = FTAssetObject(
    filePath=path,
    componentName=componentName,
    componentId=newComponent.getId(),
    assetVersionId=newftrackAssetVersion.getId()
)


scene_asset.publishAsset(iAObj)

 

Hope it helps.

L.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
1 1