
I'm trying to update an existing database document's many-to-many assocation via a function but keep getting a Server Error
whenever I attempt this code:
def associate_video_to_playlist(playlist_url, video_id):
playlist_document_id = get_appwrite_playlist_document(playlist_url)['$id']
video_document = get_appwrite_youtube_video_document(video_id)
result = documents.update_document(
APPWRITE_DATABASE_ID,
YOUTUBE_PLAYLIST_COLLECTION_ID,
playlist_document_id,
{
'youtubeVideo': video_document
}
)
# print(f'playlist document: {playlist_document["youtubeVideo"]}')
return playlist_document_id
I'm not sure whether to provide the ID of the associated document, the object itself, or what. I've checked permissions for all associated content.
Recommended threads
- Appwrite Fra Cloud Custom Domains Issue
I’m trying to configure my custom domain appwrite.qnarweb.com (CNAME pointing to fra.cloud.appwrite.io with Cloudflare proxy disabled) but encountering a TLS ce...
- Storage & Database is not allowing.
Storage & Database is not allowing to CRUD after i have logged in ? Using web SDK with next.js without any SSR or node-sdk.
- session client not allowed to create doc...
Hello all! So my issue is that I keep getting ERROR Error creating invitation: The requested service is disabled. You can enable the service from the Appwr...
