Skip to content
Back

[SOLVED] Invalid document structure: Unknown attribute: "type" when trying to create a database

  • 0
  • Resolved
  • 2
  • Self Hosted
  • Databases
videosambo
17 Nov, 2025, 19:12

Hello. I have self hosted instance running on my server and has valid endpoint and most of things are working as should. Installation is fresh install of version 1.8.0. I get error when trying to create a database ' Invalid document structure: Unknown attribute: "type"'. I tried to reinstall appwrite and also I did read docs for help and scrolled some forum posts but no help. What could cause this and how to fix?

TL;DR
Upgraded from 1.7.x to 1.8.0, missed running 'docker compose exec appwrite migrate'. Running this command resolved the issue of "Invalid document structure: Unknown attribute: 'type'". Full Appwrite setup review offered for stability and optimization. Maintenance assistance available upon request.
videosambo
17 Nov, 2025, 19:39

And logs show this:

TypeScript
appwrite  | [Error] Timestamp: 2025-11-17T19:39:15+00:00
appwrite  | [Error] Method: POST
appwrite  | [Error] URL: /v1/tablesdb
appwrite  | [Error] Type: Appwrite\Extend\Exception
appwrite  | [Error] Message: Invalid document structure: Unknown attribute: "type"
appwrite  | [Error] File: /usr/src/code/src/Appwrite/Platform/Modules/Databases/Http/Databases/Create.php
appwrite  | [Error] Line: 89
17 Nov, 2025, 21:05

Hi! I can help you troubleshoot this issue. This "Unknown attribute: 'type'" error when creating a database typically indicates a mismatch between your Appwrite version and the database schema, or an issue with the database migration after installation. Quick question: Did you migrate from an older Appwrite version to 1.8.0, or is this a completely fresh installation with no previous data? Also, are you seeing any errors in your Appwrite server logs (you can check with docker compose logs appwrite)?

21 Nov, 2025, 21:03

Now that you mentioned I did upgrade from 1.7.x to 1.8.0. I rereaded docs and found out that I missed docker compose exec appwrite migrate. I did that and looks like that resolved my issue.

22 Nov, 2025, 00:29

[SOLVED] Invalid document structure: Unknown attribute: "type" when trying to create a database

22 Nov, 2025, 08:30

Great to hear the migration fixed the issue! 🎉 If you want, I can also review your full Appwrite setup to make sure everything is properly upgraded, stable, and optimized. Since you already ran into a schema mismatch once, it might be good to double-check your containers, env vars, permissions, and database consistency small things that can prevent bigger issues later.

22 Nov, 2025, 08:32

Feel free to message me if you want me to take a look or help you with ongoing Appwrite maintenance. I’m happy to help!

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more