Skip to content
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
4f2dac8
fix(frontend): use API base path consistently
AmaLS367 May 13, 2026
7623346
refactor(api): extract amoCRM client and token refresh
AmaLS367 May 13, 2026
be897da
refactor(documents): extract document generation service
AmaLS367 May 13, 2026
92bca7d
feat(api): make backend totals the single calculation source
AmaLS367 May 13, 2026
e8eb47b
feat(config): map amoCRM custom fields by id
AmaLS367 May 13, 2026
6b167d0
feat(templates): introduce template registry
AmaLS367 May 13, 2026
045dcc4
feat(security): require server-issued generate nonce
AmaLS367 May 13, 2026
45e752b
refactor(api): isolate cache notes and logging
AmaLS367 May 13, 2026
9b2d959
docs: update setup and API security guidance
AmaLS367 May 13, 2026
373ed43
docs: add showcase assets and README navigation
AmaLS367 May 13, 2026
8cfb008
docs: reorganize documentation tree
AmaLS367 May 13, 2026
f4a523e
docs(en): split English guide into focused pages
AmaLS367 May 13, 2026
6fed2df
docs(ru): split Russian guide into focused pages
AmaLS367 May 13, 2026
2340ce0
docs: add architecture and workflow diagrams
AmaLS367 May 13, 2026
f9a1dbc
docs: add community health files
AmaLS367 May 13, 2026
c3afbbe
docs: polish badges links and repository metadata guidance
AmaLS367 May 13, 2026
953a67f
docs: update social preview image and reference in README
AmaLS367 May 13, 2026
5055c8b
feat: add GitHub social preview image for repository documentation
AmaLS367 May 13, 2026
83851af
docs: package guides with README-style navigation
AmaLS367 May 13, 2026
28e6751
feat: add github social preview image to assets directory
AmaLS367 May 13, 2026
dd15d99
docs: package root community files
AmaLS367 May 13, 2026
7996817
Merge branch 'main' into refactor/generate-api-hardening
AmaLS367 May 13, 2026
db2cad1
fix: handle filesystem write failures explicitly
AmaLS367 May 13, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: "🐛 Bug report"
description: Report a reproducible AmoDocsEngine bug.
title: "bug: "
labels: ["bug"]
body:
- type: markdown
attributes:
value: |
Do not paste real amoCRM tokens, `config/config.php`, customer data, or generated private documents.
- type: textarea
id: summary
attributes:
label: Summary
description: What broke?
validations:
required: true
- type: textarea
id: steps
attributes:
label: Reproduction steps
description: Provide minimal steps with sanitized values.
placeholder: |
1. Open public/ui.html?lead_id=...
2. Call ...
3. See ...
validations:
required: true
- type: textarea
id: expected
attributes:
label: Expected behavior
validations:
required: true
- type: textarea
id: actual
attributes:
label: Actual behavior
validations:
required: true
- type: input
id: php-version
attributes:
label: PHP version
placeholder: "8.1"
- type: textarea
id: logs
attributes:
label: Sanitized logs
description: Paste only sanitized log excerpts.
render: text
8 changes: 8 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
blank_issues_enabled: false
contact_links:
- name: Security-sensitive report
url: https://github.com/AmaLS367
about: Do not publish secrets, tokens, customer data, or exploit details in public issues.
- name: Documentation
url: https://github.com/AmaLS367/AmoDocsEngine/tree/main/docs
about: Check the documentation before opening setup or deployment questions.
42 changes: 42 additions & 0 deletions .github/ISSUE_TEMPLATE/config_deploy_help.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: "⚙️ Config or deploy help"
description: Ask for help with sanitized configuration or hosting setup.
title: "support: "
labels: ["support", "configuration"]
body:
- type: markdown
attributes:
value: |
Do not upload `config/config.php`, `config/token.json`, `.env`, real tokens, or customer data.
- type: dropdown
id: environment
attributes:
label: Environment
options:
- Shared hosting
- VPS
- Local Windows
- Local Linux/macOS
- Other
validations:
required: true
- type: textarea
id: problem
attributes:
label: Problem
description: What are you trying to configure or deploy?
validations:
required: true
- type: textarea
id: sanitized-config
attributes:
label: Sanitized config excerpt
description: Replace all secrets, domains, tokens, and customer values.
render: php
- type: textarea
id: checks
attributes:
label: Checks already run
placeholder: |
- composer install
- vendor/bin/phpunit
- opened public/ui.html?lead_id=...
23 changes: 23 additions & 0 deletions .github/ISSUE_TEMPLATE/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: "📚 Documentation issue"
description: Report unclear or outdated docs.
title: "docs: "
labels: ["documentation"]
body:
- type: input
id: page
attributes:
label: Page
description: Link or path to the affected doc page.
placeholder: docs/en/configuration.md
validations:
required: true
- type: textarea
id: issue
attributes:
label: What is unclear or outdated?
validations:
required: true
- type: textarea
id: suggested
attributes:
label: Suggested wording or structure
37 changes: 37 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: "✨ Feature request"
description: Suggest a focused improvement.
title: "feat: "
labels: ["enhancement"]
body:
- type: textarea
id: problem
attributes:
label: Problem
description: What workflow should this improve?
validations:
required: true
- type: textarea
id: proposal
attributes:
label: Proposed solution
description: Describe the smallest useful version.
validations:
required: true
- type: textarea
id: alternatives
attributes:
label: Alternatives considered
- type: dropdown
id: area
attributes:
label: Area
options:
- API
- UI
- amoCRM integration
- DOCX templates
- Security
- Documentation
- Tests
validations:
required: true
27 changes: 27 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
## 📌 Summary

-

## 🧭 Change Type

- [ ] Docs
- [ ] Bug fix
- [ ] Feature
- [ ] Refactor
- [ ] Tests
- [ ] Security/configuration

## ✅ Test Plan

- [ ] `.\vendor\bin\phpunit`
- [ ] Docs links checked, if documentation changed
- [ ] Config/security impact described, if applicable
- [ ] No secrets, tokens, logs, generated documents, or customer data committed

## 🔐 Security / Config Impact

-

## 📝 Notes

-
47 changes: 47 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
<h1 align="center">📜 Code of Conduct</h1>

<p align="center">
<strong>Clear, respectful, engineering-focused collaboration for AmoDocsEngine.</strong>
</p>

<p align="center">
<a href="README.md">🏠 README</a> ·
<a href="CONTRIBUTING.md">🤝 Contributing</a> ·
<a href="SECURITY.md">🛡️ Security</a> ·
<a href="docs/en/index.md">📚 Docs</a>
</p>

---

## ✅ Our Standard

This project expects direct, practical, and professional collaboration. Keep feedback focused on the work: code, docs, tests, security, deployment behavior, and maintainability.

| Expected | Why it matters |
| --- | --- |
| Use reproducible evidence | Maintainers can verify and fix issues faster |
| Ask clear questions | Ambiguity is cheaper to resolve early |
| Stay scoped to the project | Issues and PRs remain useful |
| Protect secrets and CRM data | Public repositories are not safe for private data |

## 👍 Good Behavior

- Use clear technical arguments.
- Provide sanitized reproduction steps.
- Assume good intent when asking for clarification.
- Respect security boundaries.
- Keep issue and PR threads focused.

## 🚫 Unacceptable Behavior

- Harassment, insults, threats, or discriminatory language.
- Publishing private information.
- Sharing tokens, secrets, customer data, or private CRM data.
- Repeated off-topic comments that make maintenance harder.
- Posting exploit details in public issues.

## 🛠️ Enforcement

Maintainers may edit, hide, or remove comments and issues that violate this code. Repeated or severe violations may lead to blocking from the repository.

Security-sensitive concerns must follow [SECURITY.md](SECURITY.md) instead of public issue discussion.
79 changes: 79 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
<h1 align="center">🤝 Contributing</h1>

<p align="center">
<strong>Small, focused, verifiable changes for a shared-hosting friendly PHP document engine.</strong>
</p>

<p align="center">
<a href="README.md">🏠 README</a> ·
<a href="docs/en/development.md">🧪 Development Docs</a> ·
<a href="SECURITY.md">🛡️ Security</a> ·
<a href="CODE_OF_CONDUCT.md">📜 Code of Conduct</a>
</p>

---

## ⚡ Fast Path

```powershell
composer install
Copy-Item config/config.example.php config/config.php
.\vendor\bin\phpunit
```

## 🧭 Contribution Map

| Change type | Start here | Required check |
| --- | --- | --- |
| Docs | `README.md`, `docs/en`, `docs/ru` | Link check + PHPUnit |
| API behavior | `api/`, `src/` | PHPUnit test for behavior |
| Templates | `templates/`, docs | Manual DOCX check if template changes |
| Security | `src/Security`, `SECURITY.md` | Token/HMAC tests |
| amoCRM integration | `src/AmoCrm` | Mocked client tests |

## 🌿 Branch Names

Use short, scoped branch names:

- `docs/readme-polish`
- `fix/generate-token-validation`
- `refactor/template-registry`
- `test/quote-service`

## ✅ Pull Request Checklist

Before opening a PR:

- [ ] Run `.\vendor\bin\phpunit`.
- [ ] Keep the PR focused on one concern.
- [ ] Check changed docs links.
- [ ] Explain config, deployment, or security impact.
- [ ] Include sanitized examples only.

## 🔒 Never Commit

Use real secrets only in ignored local files. Never commit:

- `config/config.php`
- `config/token.json`
- `.env`
- `data/`
- `documents/`
- `logs/`
- generated DOCX files
- real amoCRM/customer data

## 🧾 Commit Style

Prefer concise concern-based commits:

- `docs: update configuration guide`
- `fix(frontend): use api base path`
- `refactor(api): isolate note service`
- `test: cover field id mapping`

## 📚 Related Docs

- [English development guide](docs/en/development.md)
- [Russian development guide](docs/ru/development.md)
- [Security policy](SECURITY.md)
Loading
Loading