From 99086d4b51e59f381ea68f90d1fe3d1b12e71f87 Mon Sep 17 00:00:00 2001 From: Aleksandr Soloshenko Date: Mon, 13 Nov 2023 00:24:05 +0700 Subject: [PATCH] Added: static pages by MkDocs --- .dockerignore | 1 + LICENSE | 201 ++++++++++++++++++ Makefile | 11 +- api/requests.http | 24 ++- build/package/Dockerfile | 14 +- deployments/docker-compose/docker-compose.yml | 45 ++++ internal/config/config.go | 12 +- internal/sms-gateway/handlers/root.go | 2 +- web/mkdocs/.dockerignore | 2 + web/mkdocs/.gitignore | 2 + web/mkdocs/docs/api.md | 7 + web/mkdocs/docs/contributing.md | 12 ++ web/mkdocs/docs/favicon.ico | Bin 0 -> 67646 bytes web/mkdocs/docs/getting-started.md | 31 +++ web/mkdocs/docs/index.md | 43 ++++ web/mkdocs/docs/installation.md | 18 ++ web/mkdocs/docs/license.md | 201 ++++++++++++++++++ web/{static/images => mkdocs/docs}/logo.png | Bin web/mkdocs/docs/pricing.md | 9 + web/mkdocs/mkdocs.yml | 22 ++ web/static/getting-started.html | 28 --- web/static/index.html | 62 ------ web/static/styles.css | 40 ---- 23 files changed, 643 insertions(+), 144 deletions(-) create mode 100644 .dockerignore create mode 100644 LICENSE create mode 100644 deployments/docker-compose/docker-compose.yml create mode 100644 web/mkdocs/.dockerignore create mode 100644 web/mkdocs/.gitignore create mode 100644 web/mkdocs/docs/api.md create mode 100644 web/mkdocs/docs/contributing.md create mode 100644 web/mkdocs/docs/favicon.ico create mode 100644 web/mkdocs/docs/getting-started.md create mode 100644 web/mkdocs/docs/index.md create mode 100644 web/mkdocs/docs/installation.md create mode 100644 web/mkdocs/docs/license.md rename web/{static/images => mkdocs/docs}/logo.png (100%) create mode 100644 web/mkdocs/docs/pricing.md create mode 100644 web/mkdocs/mkdocs.yml delete mode 100644 web/static/getting-started.html delete mode 100644 web/static/index.html delete mode 100644 web/static/styles.css diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..4032ec6 --- /dev/null +++ b/.dockerignore @@ -0,0 +1 @@ +.git/ \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..f49a4e1 --- /dev/null +++ b/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. \ No newline at end of file diff --git a/Makefile b/Makefile index 39dde5f..7a840ae 100644 --- a/Makefile +++ b/Makefile @@ -35,6 +35,12 @@ build: install: go install ./cmd/$(project_name) +docker-build: + docker build -f build/package/Dockerfile -t $(image_name) --build-arg APP=$(project_name) . + +docker: + docker-compose -f deployments/docker-compose/docker-compose.yml up --build + docker-dev: docker-compose -f deployments/docker-compose/docker-compose.dev.yml up --build @@ -45,4 +51,7 @@ api-docs: view-docs: php -S 127.0.0.1:8080 -t ./api -.PHONY: init init-dev air run test install api-docs docker-dev view-docs \ No newline at end of file +clean: + docker-compose -f deployments/docker-compose/docker-compose.yml down --volumes + +.PHONY: init init-dev air run test install docker docker-build api-docs docker-dev view-docs clean \ No newline at end of file diff --git a/api/requests.http b/api/requests.http index 057bccf..548e518 100644 --- a/api/requests.http +++ b/api/requests.http @@ -1,3 +1,4 @@ +@localUrl=http://localhost:8080 @baseUrl=http://localhost:3000 ### @@ -12,20 +13,33 @@ Content-Type: application/json ### POST {{baseUrl}}/api/3rdparty/v1/message HTTP/1.1 Content-Type: application/json -Authorization: Basic IUGFXE:v4ejpbeydvjo1h +Authorization: Basic RMTJTU:yv3sqcidpqeoxc { "message": "Test", - "ttl": {{$randomInt 0 86400}}, + "ttl": 600, "phoneNumbers": [ "79990001234" ] } ### -GET {{baseUrl}}/api/3rdparty/v1/message/pRl1wf_yez5TikJb_xemU HTTP/1.1 -Authorization: Basic IUGFXE:v4ejpbeydvjo1h +GET {{baseUrl}}/api/3rdparty/v1/message/HE9_eR12bfUauavjvgS1O HTTP/1.1 +Authorization: Basic RMTJTU:yv3sqcidpqeoxc ### GET {{baseUrl}}/api/mobile/v1/message HTTP/1.1 -Authorization: Bearer KuvE4LBXzvy8QO2ZXDDMP \ No newline at end of file +Authorization: Bearer KuvE4LBXzvy8QO2ZXDDMP + +### +POST {{localUrl}}/message HTTP/1.1 +Content-Type: application/json +Authorization: Basic sms:6jH2vwEA + +{ + "message": "Test", + "ttl": 600, + "phoneNumbers": [ + "+79990001234" + ] +} \ No newline at end of file diff --git a/build/package/Dockerfile b/build/package/Dockerfile index 4fd5e9c..a9a47d0 100644 --- a/build/package/Dockerfile +++ b/build/package/Dockerfile @@ -19,6 +19,18 @@ COPY . . # RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -installsuffix cgo -o app . RUN CGO_ENABLED=0 go build -a -installsuffix cgo -o app ./cmd/${APP}/main.go +# Build MkDocs +FROM squidfunk/mkdocs-material AS mkdocs + +WORKDIR /docs + +RUN pip install mkdocs-render-swagger-plugin + +COPY web/mkdocs . + +RUN mkdocs build + + # Moving the binary to the 'final Image' to make it smaller FROM alpine:3 as prod @@ -31,7 +43,7 @@ COPY --from=build /go/bin/goose /app/goose COPY scripts/docker-entrypoint.sh /docker-entrypoint.sh -# `boilerplate` should be replaced here as well +COPY --from=mkdocs /docs/site /app/static COPY db/migrations /app/migrations COPY --from=build /go/src/app /app diff --git a/deployments/docker-compose/docker-compose.yml b/deployments/docker-compose/docker-compose.yml new file mode 100644 index 0000000..dee1325 --- /dev/null +++ b/deployments/docker-compose/docker-compose.yml @@ -0,0 +1,45 @@ +version: '3' +services: + backend: + image: capcom6/sms-gateway + build: + context: ../.. + dockerfile: ./build/package/Dockerfile + args: + - APP=sms-gateway + environment: + - DEBUG=1 + - CONFIG_PATH=config.yml + - GOOSE_DBSTRING=sms:sms@tcp(db:3306)/sms + - HTTP_LISTEN=0.0.0.0:3000 + - DATABASE_HOST=db + - DATABASE_PORT=3306 + - DATABASE_USER=sms + - DATABASE_PASSWORD=sms + - DATABASE_DATABASE=sms + ports: + - "3000:3000" + volumes: + - ../../configs/config.yml:/app/config.yml:ro + restart: 'no' + depends_on: + db: + condition: service_healthy + + db: + image: mariadb:10.6 + environment: + - MYSQL_ROOT_PASSWORD=root + - MYSQL_DATABASE=sms + - MYSQL_USER=sms + - MYSQL_PASSWORD=sms + volumes: + - mariadb-data:/var/lib/mysql + restart: 'no' + healthcheck: + test: ["CMD", "mysqladmin", "ping", "-proot", "-h", "127.0.0.1"] + timeout: 5s + retries: 10 + +volumes: + mariadb-data: \ No newline at end of file diff --git a/internal/config/config.go b/internal/config/config.go index 78861c2..8af7c81 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -16,15 +16,15 @@ type Config struct { } type HTTP struct { - Listen string `yaml:"listen"` + Listen string `yaml:"listen" env:"HTTP_LISTEN"` } type Database struct { - Host string `yaml:"host"` - Port int `yaml:"port"` - User string `yaml:"user"` - Password string `yaml:"password"` - Database string `yaml:"database"` + Host string `yaml:"host" env:"DATABASE_HOST"` + Port int `yaml:"port" env:"DATABASE_PORT"` + User string `yaml:"user" env:"DATABASE_USER"` + Password string `yaml:"password" env:"DATABASE_PASSWORD"` + Database string `yaml:"database" env:"DATABASE_DATABASE"` } type FCMConfig struct { diff --git a/internal/sms-gateway/handlers/root.go b/internal/sms-gateway/handlers/root.go index 6a09707..6740485 100644 --- a/internal/sms-gateway/handlers/root.go +++ b/internal/sms-gateway/handlers/root.go @@ -8,7 +8,7 @@ type rootHandler struct { } func (h *rootHandler) Register(app *fiber.App) { - app.Static("/", "web/static") + app.Static("/", "static") } func newRootHandler() *rootHandler { diff --git a/web/mkdocs/.dockerignore b/web/mkdocs/.dockerignore new file mode 100644 index 0000000..bc4b8ed --- /dev/null +++ b/web/mkdocs/.dockerignore @@ -0,0 +1,2 @@ +venv/ +site/ \ No newline at end of file diff --git a/web/mkdocs/.gitignore b/web/mkdocs/.gitignore new file mode 100644 index 0000000..c2679e3 --- /dev/null +++ b/web/mkdocs/.gitignore @@ -0,0 +1,2 @@ +venv/ +site/ diff --git a/web/mkdocs/docs/api.md b/web/mkdocs/docs/api.md new file mode 100644 index 0000000..ff1c6cd --- /dev/null +++ b/web/mkdocs/docs/api.md @@ -0,0 +1,7 @@ +# API + +The Android SMS Gateway provides an API that allows you to send SMS messages programmatically from your own applications or services. + +You can find the OpenAPI specification for our API at the following link: [OpenAPI Specification](https://capcom6.github.io/android-sms-gateway/). This specification includes detailed information about the available endpoints, request/response structure, and more. + +Feel free to explore it for better understanding and integration with our service. \ No newline at end of file diff --git a/web/mkdocs/docs/contributing.md b/web/mkdocs/docs/contributing.md new file mode 100644 index 0000000..bf269e7 --- /dev/null +++ b/web/mkdocs/docs/contributing.md @@ -0,0 +1,12 @@ +## Contributing + +Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**. + +If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". +Don't forget to give the project a star! Thanks again! + +1. Fork the Project +2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`) +3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`) +4. Push to the Branch (`git push origin feature/AmazingFeature`) +5. Open a Pull Request \ No newline at end of file diff --git a/web/mkdocs/docs/favicon.ico b/web/mkdocs/docs/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..6450680960d67289e94726ccd5ee883d92402690 GIT binary patch literal 67646 zcmeHwXLlAywyw{&`wPzJ`|+%GCmqk&V;h?sC32Dk3WzLnP9oKIpaLG zaR7|Lm}r8DN(is#KD(;-+ok4J00S0SGi!TS*j2CSXQ!&J?tbHq|Kk70j(vmw{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f8oU4AaBb2bu3g*I=CvNg)SbVoT)ysB uU8AaNRHXw|I#8tpRXXsx=)fCQ|EszJRac`, ``, and `` with the values obtained in step 4: + + ``` + curl -X POST -u : -H "Content-Type: application/json" -d '{ "message": "Hello, world!", "phoneNumbers": ["79990001234", "79995556677"] }' http://:8080/message + ``` + +## Cloud server + +If you need to send messages with dynamic or shared device IP, you can use the cloud server. The best part? No registration, email, or phone number is required to start using it. + +1. Start the app on the device. +2. Activate the `Cloud server` switch. +3. Tap the `Offline` button at the bottom of the screen. +4. In the `Cloud server` section, the credentials for basic authentication will be displayed. +5. Make a curl call using a command like the following, replacing `` and `` with the values obtained in step 4: + + ``` + curl -X POST -u : -H "Content-Type: application/json" -d '{ "message": "Hello, world!", "phoneNumbers": ["79990001234", "79995556677"] }' https://sms.capcom.me/api/3rdparty/v1/message + ``` \ No newline at end of file diff --git a/web/mkdocs/docs/index.md b/web/mkdocs/docs/index.md new file mode 100644 index 0000000..62ab97a --- /dev/null +++ b/web/mkdocs/docs/index.md @@ -0,0 +1,43 @@ +# Android SMS Gateway + +![Project logo](logo.png) + +Android SMS Gateway turns your Android smartphone into an SMS gateway. It's a lightweight application allowing you to send SMS messages programmatically via API. This makes it ideal for integrating SMS functionality into your own applications or services. + +## Features + +- **Send SMS programmatically:** Use our API to send messages directly from your own applications or services. +- **Supports Android 5.0 and above:** The application is compatible with Android 5.0 and later versions. +- **Message status tracking:** Monitor the status of your sent messages in real-time. +- **Starts at boot:** The application starts running as soon as your device boots up. +- **Prevents sleep mode:** Your device won't go to sleep while the application is running, ensuring continuous service. + +## Ideal For + +- Notifications +- Alerts +- Two-factor authentication codes + +Android SMS Gateway provides a convenient and reliable solution, whether you need to send notifications, alerts, or two-factor authentication codes. + +## Project Stage + +The project is currently in the MVP stage. We're actively working on adding more features and improving the existing ones. + +## Get Started + +Getting started with Android SMS Gateway is easy and straightforward. No registration, email, or phone number is required to create an account and start using the app. + +Check out our [Getting Started Guide](getting-started.md) to learn how to install and use Android SMS Gateway. + +## Contributing + +Interested in contributing? Read our [Contributing Guide](contributing.md) to find out how you can help. + +## License + +This project is licensed under the [Apache License 2.0](license.md). + +## Contact + +If you have any questions or suggestions, feel free to [create an issue](https://github.com/capcom6/android-sms-gateway/issues/new) or [send us an email](mailto:i@capcom.me). \ No newline at end of file diff --git a/web/mkdocs/docs/installation.md b/web/mkdocs/docs/installation.md new file mode 100644 index 0000000..c97a13e --- /dev/null +++ b/web/mkdocs/docs/installation.md @@ -0,0 +1,18 @@ +# Installation + +You can install app to your device from prebuilt APK or by building from sources. + +## Prerequisites + +You need an Android device with Android 5.0 (Lollipop) or above for using the application. + +## Installation from APK + +1. Navigate to the [Releases](https://github.com/capcom6/android-sms-gateway/releases) page. +2. Download the latest APK file from the list of available releases. +3. Transfer the APK file to your Android device. +4. On your Android device, go to **Settings** > **Security** (or **Privacy** on some devices). +5. Enable the **Unknown sources** option to allow installation of apps from sources other than the Play Store. +6. Use a file manager app to navigate to the location of the downloaded APK file. +7. Tap on the APK file to start the installation process. +8. Follow the on-screen prompts to complete the installation. \ No newline at end of file diff --git a/web/mkdocs/docs/license.md b/web/mkdocs/docs/license.md new file mode 100644 index 0000000..f49a4e1 --- /dev/null +++ b/web/mkdocs/docs/license.md @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. \ No newline at end of file diff --git a/web/static/images/logo.png b/web/mkdocs/docs/logo.png similarity index 100% rename from web/static/images/logo.png rename to web/mkdocs/docs/logo.png diff --git a/web/mkdocs/docs/pricing.md b/web/mkdocs/docs/pricing.md new file mode 100644 index 0000000..bd6c9e7 --- /dev/null +++ b/web/mkdocs/docs/pricing.md @@ -0,0 +1,9 @@ +# Pricing + +Using the Android SMS Gateway comes with different pricing based on the server you choose to use: + +- **Local Server**: Utilizing the local server to send messages is always free, with no restrictions or limits. + +- **Cloud Server**: Using the cloud server to send your messages may be subject to certain limits. If you are planning to send more than 1000 messages per month using the cloud server, we recommend reaching out to us for more information and possible arrangements. + +For further inquiries or clarification, feel free to [contact us](mailto:i@capcom.me). \ No newline at end of file diff --git a/web/mkdocs/mkdocs.yml b/web/mkdocs/mkdocs.yml new file mode 100644 index 0000000..32a82c5 --- /dev/null +++ b/web/mkdocs/mkdocs.yml @@ -0,0 +1,22 @@ +site_name: Android SMS Gateway +site_url: https://sms.capcom.me +theme: + name: material +nav: + - Home: index.md + - Installation: installation.md + - Getting Started: getting-started.md + - API: api.md + - Pricing: pricing.md + - Contributing: contributing.md + - License: license.md +plugins: + - search + - render_swagger + - minify: + minify_html: true + minify_js: true + minify_css: true + htmlmin_opts: + remove_comments: true + cache_safe: true diff --git a/web/static/getting-started.html b/web/static/getting-started.html deleted file mode 100644 index 8ddaea5..0000000 --- a/web/static/getting-started.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - - Getting Started - Android SMS Gateway - - - - -
-
-

Getting Started - Android SMS Gateway

-
-
- -
-

Step 1: Installation

-

Here you provide instructions about how to install your application.

- -

Step 2: Configuration

-

Here you provide instructions about how to configure your application after it has been installed.

- -

Step 3: Usage

-

Here you provide instructions about how to use your application.

-
- - - \ No newline at end of file diff --git a/web/static/index.html b/web/static/index.html deleted file mode 100644 index 842c795..0000000 --- a/web/static/index.html +++ /dev/null @@ -1,62 +0,0 @@ - - - - - Android SMS Gateway - - - - -
-
-

Android SMS Gateway

-
-
- -
- Project logo -

Android SMS Gateway turns your Android smartphone into an SMS gateway. It's a lightweight application - allowing you to send SMS messages programmatically via API. This makes it ideal for integrating SMS - functionality into your own applications or services.

- -

Features

-
    -
  • Send SMS programmatically: Use our API to send messages directly from your own applications or services. -
  • -
  • Supports Android 5.0 and above: The application is compatible with Android 5.0 and later versions.
  • -
  • Message status tracking: Monitor the status of your sent messages in real-time.
  • -
  • Starts at boot: The application starts running as soon as your device boots up.
  • -
  • Prevents sleep mode: Your device won't go to sleep while the application is running, ensuring continuous - service.
  • -
- -

Ideal For

-
    -
  • Notifications
  • -
  • Alerts
  • -
  • Two-factor authentication codes
  • -
- -

Project Stage

-

The project is currently in the MVP stage. We're actively working on adding more features and improving the - existing ones.

- -

Get Started

-

Check out our Getting Started Guide to learn how to install and use - Android SMS Gateway.

- -

Contributing

-

Interested in contributing? Read our Contributing Guide to find out how you - can help.

- -

License

-

This project is licensed under the Apache License 2.0.

- -

Contact

-

If you have any questions or suggestions, feel free to create an issue or send us an email.

-
- - - \ No newline at end of file diff --git a/web/static/styles.css b/web/static/styles.css deleted file mode 100644 index 2a92dcc..0000000 --- a/web/static/styles.css +++ /dev/null @@ -1,40 +0,0 @@ -body { - font-family: Arial, sans-serif; - margin: 0; - padding: 0; - background-color: #f4f4f4; -} - -.container { - width: 80%; - margin: auto; - overflow: hidden; -} - -header { - background: #50a8a8; - color: white; - padding-top: 30px; - min-height: 70px; - border-bottom: #396969 3px solid; -} - -header a { - color: #ffffff; - text-decoration: none; - text-transform: uppercase; - font-size: 16px; -} - -header h1 { - float: left; - margin: 0; -} - -header #underline { - color: #396969; -} - -h2 { - color: #396969; -} \ No newline at end of file