Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
28f3716
Update README.md
Sin-Estres-dev Jun 22, 2025
916b55d
Update README.md
Sin-Estres-dev Jan 16, 2026
e467511
Update README.md
Sin-Estres-dev Jan 16, 2026
e4c2110
Update README.md
Sin-Estres-dev Jan 19, 2026
dd23b32
Add split-sheet template and example for 5 writers
Sin-Estres-dev Jan 16, 2026
916a535
Update docs/splits/split-sheet-5-writers.md
Sin-Estres-dev Jan 21, 2026
5544b61
Update docs/splits/split-sheet-5-writers.md
Sin-Estres-dev Jan 21, 2026
f719596
Document repository capabilities and usage (#10)
Copilot Feb 5, 2026
4c7000e
Initial plan (#12)
Copilot Feb 5, 2026
692efbb
Initial plan (#15)
Sin-Estres-dev Feb 5, 2026
5c0410c
Save changes to package.json and package-lock.json
SinEstresOrrantia Feb 6, 2026
f4cb85a
Merge branch 'Sin-Estres-dev-patch-2' of https://github.com/Sin-Estre…
SinEstresOrrantia Feb 6, 2026
5148b6c
Add legal documentation, licenses, and action plan
SinEstresOrrantia Feb 6, 2026
ef75883
Add copilot-termux-setup/ to .gitignore
SinEstresOrrantia Feb 7, 2026
455a528
Add copilot-termux-setup/ to .gitignore
SinEstresOrrantia Feb 7, 2026
a979ffe
Add Copilot instructions for repository
Copilot Feb 8, 2026
5fd506b
Clarify industry identifier formats in Copilot instructions
Copilot Feb 8, 2026
fa9fe06
Add database tables for publishing royalties, split sheets, and PRO r…
Copilot Feb 8, 2026
1ddaa81
Address code review feedback: improve constraints and indexes
Copilot Feb 8, 2026
9152a0f
Add comprehensive documentation for schema enhancements
Copilot Feb 8, 2026
7e04e73
Update CAPABILITIES.md
Sin-Estres-dev Feb 8, 2026
567c94f
Add song metadata catalog and split sheet for No Te Vayas Lejos
Copilot Feb 8, 2026
396ea75
Address code review: fix placeholder values in seed catalog
Copilot Feb 8, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
Empty file added -H
Empty file.
4 changes: 4 additions & 0 deletions .env.local
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
DATABASE_URL=postgresql://localhost:5432/strezless
PORT=3000
NODE_ENV=development
DATABASE_URL=postgresql://u0_a489@localhost:5432/music_metadata
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DATABASE_URL is defined twice with conflicting values. The second definition on line 4 will override the first. Remove one of these entries and ensure the correct database URL is used.

Suggested change
DATABASE_URL=postgresql://u0_a489@localhost:5432/music_metadata

Copilot uses AI. Check for mistakes.
197 changes: 197 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,197 @@
# Copilot Instructions for Strezless Musick Productionz

## Project Overview
Strezless is a music production business management platform. This repository provides a backend API for managing artist profiles, music releases, distribution, and music industry business documentation.

**Domain Context**: Music business operations, including artist rights management, split sheets, PRO (Performance Rights Organization) registration, and industry standard identifiers (IPI, ISNI, ISRC, ISWC, UPC).

## Tech Stack
- **Runtime**: Node.js (CommonJS modules)
- **Framework**: Express.js 5.x
- **Database**: PostgreSQL with UUID primary keys
- **Environment**: dotenv for configuration (.env.local)
- **Key Dependencies**:
- `pg` for PostgreSQL connection pooling
- `body-parser` for request parsing
- `express` for REST API

## Project Structure
```
/
├── index.js # Main Express app entry point
├── routes/ # API route handlers
│ └── artistProfile.js # Artist management endpoints
├── database/ # Database schema and migrations
│ └── schema.sql # PostgreSQL schema with industry identifiers
├── docs/ # Music business documentation
│ ├── splits/ # Split sheet templates
│ └── legal/ # Legal agreements and guides
└── .github/ # GitHub configuration
```

## Development Workflow

### Running the Application
```bash
# Install dependencies
npm install

# Development server (default port 3000)
npm run dev

# The server runs at http://localhost:3000
```

### Environment Variables
Required in `.env.local`:
- `DATABASE_URL`: PostgreSQL connection string
- `PORT`: Server port (optional, defaults to 3000)
- `NODE_ENV`: Environment (development/production)

### API Endpoints
Base URL: `http://localhost:3000`

- `POST /api/artist/profile` - Create artist profile
- `GET /api/artist/profile/:id` - Get artist profile
- `PUT /api/artist/profile/:id` - Update artist profile
- `PUT /api/artist/identifiers/:artistId` - Update industry identifiers
- `GET /api/artist/search` - Search artists by identifiers
- `GET /health` - Health check endpoint

## Coding Standards & Conventions

### JavaScript Style
- Use CommonJS modules (`require`/`module.exports`)
- Use `async/await` for asynchronous operations
- Always use transaction blocks (BEGIN/COMMIT/ROLLBACK) for multi-step database operations
- Use connection pooling (`pool.connect()`) with proper client release in `finally` blocks
- Include JSDoc comments for route handlers
- Use destructuring for request parameters

### Database Conventions
- **Primary Keys**: Use UUID with `gen_random_uuid()`
- **Timestamps**: Include `created_at` and `updated_at` (auto-managed by triggers)
- **Naming**: Use snake_case for column names, plural for table names
- **Industry Identifiers**:
- IPI (Interested Parties Information): 9 numeric digits plus 2 check digits (11 characters total with formatting)
- ISNI (International Standard Name Identifier): 16 digits
- ISRC (International Standard Recording Code): 12 characters (format: CC-XXX-YY-NNNNN)
- ISWC (International Standard Musical Work Code): Format T-XXXXXXXXX-C (11 characters including prefix T and check digit)
- UPC (Universal Product Code): 12 digits
- EIN (Employer Identification Number): US tax ID (format: XX-XXXXXXX)

### Error Handling
- Always wrap async database operations in try/catch
- Use transaction rollback on errors
- Return JSON responses with consistent format:
```javascript
{
success: true/false,
data: {...}, // on success
message: "...", // descriptive message
error: "..." // error details (development only)
}
```
- Log errors with `console.error()` before sending response
- Use appropriate HTTP status codes (201 for created, 404 for not found, 500 for server errors)

### API Response Format
All API responses should follow this structure:
```javascript
{
success: boolean,
data?: object | array,
message?: string,
error?: string,
count?: number // for list/search endpoints
}
```

### CORS Configuration
- Development: Allow all origins (configured in index.js)
- Production: Configure CORS properly with specific origins

## Music Industry Specific Guidelines

### Artist Profiles
- `career_level` must be one of: 'emerging', 'indie', 'established', 'professional', 'signed'
- Always validate industry identifiers format before storing
- Email is required and unique across artists
- Genres are stored as PostgreSQL arrays

### Releases & Tracks
- `release_type` options: 'single', 'ep', 'album', 'compilation', 'live'
- `distribution_status`: 'draft', 'submitted', 'processing', 'live', 'taken_down'
- ISRC codes are mandatory and unique for each track
- DDEX compliance tracking is required for distribution

### Split Sheets & Contributors
- Ownership percentages must sum to 100% for each track
- `role` options: 'writer', 'composer', 'producer', 'performer', 'featured_artist'
- `split_type` categories: 'publishing', 'master', 'performance'
- Always store contributor IPI/ISNI if available

### Documentation
- Split sheets are in `/docs/splits/`
- Legal templates are in `/docs/legal/`
- Maintain markdown format for all documentation
- Follow existing template structure when adding new documents

## Security Requirements
- Never commit sensitive data (API keys, database credentials, etc.)
- Use environment variables for all sensitive configuration
- Validate all user input before database queries
- Use parameterized queries to prevent SQL injection
- Store hashed passwords only (when authentication is added)
- Configure SSL for production database connections

## Testing
Current state: No test infrastructure exists yet.
When adding tests in the future:
- Consider using Jest or Mocha for testing
- Test database operations with a test database
- Mock external API calls
- Test validation logic thoroughly

## Dependencies
- Avoid adding new dependencies unless absolutely necessary
- When adding dependencies, ensure they are actively maintained
- Review security advisories before adding packages
- Update package.json and package-lock.json together

## Important Notes
- This is a music business application - understand the domain context (PRO registration, split sheets, publishing rights)
- Industry identifiers (IPI, ISNI, ISRC, etc.) follow international standards - validate format
- Transaction integrity is critical for artist profile and identifier operations
- Social links are stored as JSONB for flexibility
- Always release database clients in finally blocks
- The application uses Express 5.x (note differences from Express 4.x)

## Common Tasks

### Adding a New API Endpoint
1. Add route handler in appropriate file in `/routes/`
2. Include JSDoc comment describing the endpoint
3. Use async/await with proper error handling
4. Follow consistent response format
5. Release database connections properly

### Adding Database Tables
1. Update `/database/schema.sql`
2. Add appropriate indexes for foreign keys and frequently queried columns
3. Include `created_at` and `updated_at` timestamps
4. Add trigger for auto-updating `updated_at`
5. Use UUID for primary keys

### Working with Music Business Documentation
1. Follow existing markdown template structure
2. Store in appropriate `/docs/` subdirectory
3. Reference relevant PRO requirements and industry standards
4. Include examples where helpful

## References
- Express.js Documentation: https://expressjs.com/
- PostgreSQL Documentation: https://www.postgresql.org/docs/
- DDEX Standards: https://ddex.net/
- ISRC Information: https://www.usisrc.org/
- IPI Database: https://www.cisac.org/
14 changes: 11 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
# Dependencies
node_modules/

# Environment files
.env
.env.local

# Composer
composer.phar
/vendor/

# Commit your application's lock file https://getcomposer.org/doc/01-basic-usage.md#commit-your-composer-lock-file-to-version-control
# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
# composer.lock

# Build artifacts
copilot-termux-setup/
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 Omar Dejesu Orrantia (Sin Estres)

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
55 changes: 54 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,55 @@
# Strezless-Musick-Productionz-Founder
# Strezless Musick Productionz

On a quest to fulfill a childhood dream, Sin Estres has launched a business pursuit and is determined to finish that which he started to the very last breath in him.

## About

Strezless Musick Productionz is a music production label founded by Sin Estres (Omar Orrantia). This repository contains documentation, templates, and resources to support the music production business from the ground up.

## What Can You Do?

This repository helps you:
- 📝 **Manage Rights**: Track song ownership and writer contributions with split sheet templates
- 📄 **Legal Documentation**: Maintain proper records for PROs, publishers, and contracts
- 🤝 **Collaborate**: Standardize documentation across team members and projects
- 🎵 **Organize**: Keep all music business documentation in one place

For a comprehensive list of capabilities and potential features, see [docs/CAPABILITIES.md](docs/CAPABILITIES.md).

## Getting Started

To get a local copy up and running, follow these simple steps:

### Installation

1. Clone the repo
```sh
git clone https://github.com/Sin-Estres-dev/Strezless.git
```

2. Navigate to the repository
```sh
cd Strezless
```

3. Browse the templates in the `/docs` folder

## Available Templates

- **Split Sheets**: `/docs/splits/split-sheet-5-writers.md` - Track ownership for songs with multiple writers
- **Split Sheet — No Te Vayas Lejos**: `/docs/splits/no-te-vayas-lejos.md` - Metadata & ownership for the single

## Catalog

- **Seed Data**: `/database/seed-catalog.sql` - Artist profile and release metadata for "No Te Vayas Lejos" by Sin Estres

## Contributing

Experimenting with a music career take-off from scratch! Anyone with new ideas is welcomed, and contributions will definitely be taken into consideration.

### Starring Artist
**Sin Estres** (Omar Orrantia)

## License

This project is open for collaboration and ideas sharing.
1 change: 1 addition & 0 deletions Strezless
Submodule Strezless added at 692efb
Empty file added bio:
Empty file.
Empty file added career_level:
Empty file.
Loading
Loading