{"id":16966242,"url":"https://github.com/scottlepp/sql-proxy","last_synced_at":"2025-04-11T23:23:52.710Z","repository":{"id":40634921,"uuid":"241401766","full_name":"scottlepp/sql-proxy","owner":"scottlepp","description":"A container to connect to any SQL database and execute SQL statements.","archived":false,"fork":false,"pushed_at":"2020-10-10T11:20:11.000Z","size":28200,"stargazers_count":3,"open_issues_count":1,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-25T19:15:22.384Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/scottlepp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-02-18T15:50:22.000Z","updated_at":"2022-10-19T12:00:43.000Z","dependencies_parsed_at":"2022-09-09T00:42:16.234Z","dependency_job_id":null,"html_url":"https://github.com/scottlepp/sql-proxy","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scottlepp%2Fsql-proxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scottlepp%2Fsql-proxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scottlepp%2Fsql-proxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scottlepp%2Fsql-proxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/scottlepp","download_url":"https://codeload.github.com/scottlepp/sql-proxy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248493630,"owners_count":21113289,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-10-14T00:05:11.533Z","updated_at":"2025-04-11T23:23:52.686Z","avatar_url":"https://github.com/scottlepp.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SQL Proxy\n\nAllows connecting to any SQL database/datasource over HTTP without the need of drivers.\n\n## Getting Started\n\nClone the repo.\n\n### Prerequisites\n\nInstall Java, Gradle, and Docker\n\n### Installing\n\nStep 1: Build with build script:\n```\n./build.sh\n```\n\nStep 2: Run the container\n```\ndocker run -p 8081:8081 -t gs-springboot-sql-proxy\n```\n\n## Development\n\nUsing IntelliJ with Gradle just run the application.\n\n### Using the Proxy\n\nStep 1:  Connect\n\n* using POSTMAN or CURL (or whatever http client you want)\n\nPOST to localhost:8081/connect\n```\n{\n \"username\": \"[database user]\",\n \"password\": \"[database password]\",\n \"type\": \"[database type (sqlserver, oracle, mysql, postgres, snowflake, etc)]\",\n \"host\": \"[database host]\",\n \"port\": \"[database port]\",\n \"database\": \"[defaut database]\",\n \"params\": {\"[custom]\": \"[value]\", \"[custom2]\": \"[value]\", ...}\n}\n```\n\nSql Server Example\n```\n{\n \"username\": \"sa\",\n \"password\": \"abcd123\",\n \"type\": \"sqlserver\",\n \"host\": \"localhost\",\n \"port\": \"1433\",\n \"database\": \"\",\n}\n```\n\nSnowflake example:\n```\ncurl -XPOST localhost:8081/connect -H 'Content-type: application/json' -d '{\"username\": \"user\",\"password\": \"password\",\"type\": \"snowflake\",\"host\": \"my.db.host\",\"port\": \"1234\",\"database\": \"MY_DB\"}'\n```\n\nStep 2: Query\n\nhttp://localhost:8081/query?sql=[sql statement]\n\nExample (sql server):\n\nhttp://localhost:8081/query?sql=select * from spt_monitor\n\nExample (Snowflake):\n```\ncurl -XGET \"http://localhost:8081/query?sql=SELECT%20*%20FROM%20mytable;\"\n```\n\n## Deployment\n\nDeploy the container with Docker, Kubernetes, Portainer, etc\n\n## Built With\n\n* Gradle\n* Docker\n* Spring Boot\n\n## Contributing\n\n\n## Versioning\n\nWe use [SemVer](http://semver.org/) for versioning. For the versions available, see the [tags on this repository](https://github.com/your/project/tags).\n\n## Authors\n\n* **Scott Lepper**\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details\n\n## Acknowledgments\nhttps://spring.io/guides/gs/spring-boot-docker/\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscottlepp%2Fsql-proxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscottlepp%2Fsql-proxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscottlepp%2Fsql-proxy/lists"}