{"id":20284320,"url":"https://github.com/mahabubx7/cinebook","last_synced_at":"2026-04-13T14:32:34.069Z","repository":{"id":211499377,"uuid":"727887499","full_name":"mahabubx7/cinebook","owner":"mahabubx7","description":"Cinebook (Backend APIs): A platform for all cineplex to sell tickets online","archived":false,"fork":false,"pushed_at":"2024-09-12T09:49:28.000Z","size":511,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-02T21:53:46.528Z","etag":null,"topics":["adonisjs-framework","authorization","docker","docker-compose","json-api","nodejs","pbac","postgresql","rbac-authorization","redis","restful-api","swagger","token-based-authentication","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mahabubx7.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-05T19:28:50.000Z","updated_at":"2024-09-12T09:49:27.000Z","dependencies_parsed_at":"2023-12-31T13:24:48.257Z","dependency_job_id":"d8b76f57-b23b-4a65-a4b9-d3badd3a6682","html_url":"https://github.com/mahabubx7/cinebook","commit_stats":null,"previous_names":["mahabubx7/cinebook"],"tags_count":0,"template":false,"template_full_name":"mahabubx7/adonis-api-starter","purl":"pkg:github/mahabubx7/cinebook","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahabubx7%2Fcinebook","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahabubx7%2Fcinebook/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahabubx7%2Fcinebook/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahabubx7%2Fcinebook/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mahabubx7","download_url":"https://codeload.github.com/mahabubx7/cinebook/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahabubx7%2Fcinebook/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31757477,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-13T13:27:56.013Z","status":"ssl_error","status_checked_at":"2026-04-13T13:21:23.512Z","response_time":93,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["adonisjs-framework","authorization","docker","docker-compose","json-api","nodejs","pbac","postgresql","rbac-authorization","redis","restful-api","swagger","token-based-authentication","typescript"],"created_at":"2024-11-14T14:19:18.486Z","updated_at":"2026-04-13T14:32:34.044Z","avatar_url":"https://github.com/mahabubx7.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CineBook - Theater's online ticket booking\n\n\n### Backend API - AdonisJs (v5) + PostgreSQL\n\n\u003e This is only the backend application to serve the server-side logics and processed APIs to the client applications like website or mobile apps.\n\n##### Database Diagram `ERD` [initial]\n\n\u003e Corrections are coming soon.\n\n![erd](./erd.jpg)\n\n##### Application workflows\n\n\u003e Just demonstrating the basic workflow of this application\n\n**Latest Movies \u0026 Select a Show**\n\n```mermaid\nflowchart TD\nA[Request GET: `/movie`] --\u003e B[Array :: of Movies : includes theater that running it];\nB -- Select a `Theater` GET: /theater/:id --\u003e C[Object :: Theater : includes screenings, required query movieId];\n\nC -- Choose a show GET: /screen/shows?movieId=X\u0026theaterId=Y --\u003e D[Array :: Shows including movie \u0026 theater info];\n```\n\n**Book a seat for the selected show**\n\n```mermaid\nflowchart TD\nA[Request GET: /screen/show/:id] --\u003e B[Object :: Show : includes auditoriums with related info];\nB -- Select an Auditorium GET: /auditorium/:id --\u003e C[Object :: Auditorium info includes capacity of seats \u0026 more];\nC -- Selects seats \u0026 make booking POST: /booking  --\u003e D[Process :: BookingDto into a booking record with validations];\nE(Seat Booking process ends);\nD --  Accepted  --\u003e E;\nD --  Declined  --\u003e E;\n```\n\n**Some necessary hints**\n\n```typescript\n// Seat :: BookingDto\n/**\n * @User by authentication automatically grabs the 'userId' of users/customer\n */\ninterface BookingDto {\n  showId: number // selected: screening (i.e. Movie(1): Morning show 6AM to 10AM)\n  auditoriumId: number // selected: auditorium (i.e. SuperComfortAC-5)\n  date: string // i.e. '2023-12-24' YYYY-MM-DD\n  seats: string[] // i.e. ['A12', 'A13', 'A14']\n}\n\n// Example Record: Accepted\n/**\n * @Unique Set: ['showId', 'seatNumber', 'auditoriumId', 'date']\n * @Combination this Set makes sure that there is no duplicate record of booking\n */\nconst bookingRecords = [\n  // each row \u003c--\u003e per seat\n  {\n    id: 1,\n    userId: 777, // user-id @customer\n    showId: 1, // screening\n    seatNumber: 'A12', // each seat number\n    auditoriumId: 2, // auditorium\n    date: '2023-12-24', // YYYY-MM-DD\n    status: 'pending', // status @enum ['pending', 'booked', 'available']\n  },\n  // ... more like this\n]\n```\n\n###### Motivation\n\nWhen I was preparing myself and trying to make some good portfolios that can make impression, I thought about many like e-commerce, rental, and some others as quite popular among new developers like me.\n\nLater I decided to make some little \u0026 unique things from others to make a small difference. Then I choose this idea. Because, its quite different from any regular new developer's portfolio showcase.\n\n###### More information\n\nThis application serves `JSON` API only. I'm using a very good node.js based framework called `AdonisJs` and `PostgreSQL` database for this.\n\n```yml\nRuntime: Nodejs (\u003e= 18.x) :: LTS preferred\nFramework: AdonisJs (v5)\nDatabases: [\n  PostgreSQL, # As primary database\n  Redis, # As system data helper\n]\nDbDriver: Lucid ORM (knex.js)\nTypeSafe: YES \u003cTypeScript\u003e\nAuthentication: @adonisjs/auth\nAuthorization: @adonisjs/bouncer (policy)\nEmail: @adonisjs/mailer (smtp) + mjml\nDocs: Swagger (OpenApi v3)\nTest: @japa # adonisjs uses Japa\nStorage: @adonisjs/drive-s3 # MinIO or AWS S3\n```\n\n**Movie API usage**\n\n\u003e To fetch movie details: I am using the `TheMovieDB (TMDB)`\n\nFetch Movie poster image: `https://image.tmdb.org/t/p/w600_and_h900_bestv2/{link}`\n\n\u003e Note: This is a portfolio or prototype based backend api based application with NodeJs-stack. For more info, please contact me @mahabubx7 [`iosmahabub@gmail.com`]\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahabubx7%2Fcinebook","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmahabubx7%2Fcinebook","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahabubx7%2Fcinebook/lists"}