a25097108d
- Remove separate AI worker service - Added generation limits: FREE: 1000/month (For the beta version) PRO: 500/month ENTERPRISE: 1000/month - Integrate AI functionality into main API routes - Added monthly generations reset and usage tier upgrade API routes - Upgrade tier page to be added along with profile page section
236 lines
5.7 KiB
JSON
236 lines
5.7 KiB
JSON
{
|
|
"version": "5",
|
|
"dialect": "sqlite",
|
|
"id": "3241d14f-687f-4134-94ab-88bf36e8611e",
|
|
"prevId": "00000000-0000-0000-0000-000000000000",
|
|
"tables": {
|
|
"sandbox": {
|
|
"name": "sandbox",
|
|
"columns": {
|
|
"id": {
|
|
"name": "id",
|
|
"type": "text",
|
|
"primaryKey": true,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"name": {
|
|
"name": "name",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"type": {
|
|
"name": "type",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"visibility": {
|
|
"name": "visibility",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false
|
|
},
|
|
"createdAt": {
|
|
"name": "createdAt",
|
|
"type": "integer",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false,
|
|
"default": "CURRENT_TIMESTAMP"
|
|
},
|
|
"user_id": {
|
|
"name": "user_id",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"likeCount": {
|
|
"name": "likeCount",
|
|
"type": "integer",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false,
|
|
"default": 0
|
|
},
|
|
"viewCount": {
|
|
"name": "viewCount",
|
|
"type": "integer",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false,
|
|
"default": 0
|
|
}
|
|
},
|
|
"indexes": {
|
|
"sandbox_id_unique": {
|
|
"name": "sandbox_id_unique",
|
|
"columns": [
|
|
"id"
|
|
],
|
|
"isUnique": true
|
|
}
|
|
},
|
|
"foreignKeys": {
|
|
"sandbox_user_id_user_id_fk": {
|
|
"name": "sandbox_user_id_user_id_fk",
|
|
"tableFrom": "sandbox",
|
|
"tableTo": "user",
|
|
"columnsFrom": [
|
|
"user_id"
|
|
],
|
|
"columnsTo": [
|
|
"id"
|
|
],
|
|
"onDelete": "no action",
|
|
"onUpdate": "no action"
|
|
}
|
|
},
|
|
"compositePrimaryKeys": {},
|
|
"uniqueConstraints": {}
|
|
},
|
|
"user": {
|
|
"name": "user",
|
|
"columns": {
|
|
"id": {
|
|
"name": "id",
|
|
"type": "text",
|
|
"primaryKey": true,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"name": {
|
|
"name": "name",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"email": {
|
|
"name": "email",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"username": {
|
|
"name": "username",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"avatarUrl": {
|
|
"name": "avatarUrl",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false
|
|
},
|
|
"createdAt": {
|
|
"name": "createdAt",
|
|
"type": "integer",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false,
|
|
"default": "CURRENT_TIMESTAMP"
|
|
},
|
|
"generations": {
|
|
"name": "generations",
|
|
"type": "integer",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false,
|
|
"default": 0
|
|
}
|
|
},
|
|
"indexes": {
|
|
"user_id_unique": {
|
|
"name": "user_id_unique",
|
|
"columns": [
|
|
"id"
|
|
],
|
|
"isUnique": true
|
|
},
|
|
"user_username_unique": {
|
|
"name": "user_username_unique",
|
|
"columns": [
|
|
"username"
|
|
],
|
|
"isUnique": true
|
|
}
|
|
},
|
|
"foreignKeys": {},
|
|
"compositePrimaryKeys": {},
|
|
"uniqueConstraints": {}
|
|
},
|
|
"users_to_sandboxes": {
|
|
"name": "users_to_sandboxes",
|
|
"columns": {
|
|
"userId": {
|
|
"name": "userId",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"sandboxId": {
|
|
"name": "sandboxId",
|
|
"type": "text",
|
|
"primaryKey": false,
|
|
"notNull": true,
|
|
"autoincrement": false
|
|
},
|
|
"sharedOn": {
|
|
"name": "sharedOn",
|
|
"type": "integer",
|
|
"primaryKey": false,
|
|
"notNull": false,
|
|
"autoincrement": false
|
|
}
|
|
},
|
|
"indexes": {},
|
|
"foreignKeys": {
|
|
"users_to_sandboxes_userId_user_id_fk": {
|
|
"name": "users_to_sandboxes_userId_user_id_fk",
|
|
"tableFrom": "users_to_sandboxes",
|
|
"tableTo": "user",
|
|
"columnsFrom": [
|
|
"userId"
|
|
],
|
|
"columnsTo": [
|
|
"id"
|
|
],
|
|
"onDelete": "no action",
|
|
"onUpdate": "no action"
|
|
},
|
|
"users_to_sandboxes_sandboxId_sandbox_id_fk": {
|
|
"name": "users_to_sandboxes_sandboxId_sandbox_id_fk",
|
|
"tableFrom": "users_to_sandboxes",
|
|
"tableTo": "sandbox",
|
|
"columnsFrom": [
|
|
"sandboxId"
|
|
],
|
|
"columnsTo": [
|
|
"id"
|
|
],
|
|
"onDelete": "no action",
|
|
"onUpdate": "no action"
|
|
}
|
|
},
|
|
"compositePrimaryKeys": {},
|
|
"uniqueConstraints": {}
|
|
}
|
|
},
|
|
"enums": {},
|
|
"_meta": {
|
|
"schemas": {},
|
|
"tables": {},
|
|
"columns": {}
|
|
}
|
|
} |