{"id":19712167,"url":"https://github.com/fmstrat/shorten","last_synced_at":"2025-04-29T18:30:51.192Z","repository":{"id":25879241,"uuid":"29319515","full_name":"Fmstrat/shorten","owner":"Fmstrat","description":"A URL Shortening and Privacy Tool for ownCloud","archived":false,"fork":false,"pushed_at":"2017-01-21T22:09:23.000Z","size":62,"stargazers_count":31,"open_issues_count":28,"forks_count":14,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-04-05T18:52:03.374Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","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/Fmstrat.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":"2015-01-15T21:39:22.000Z","updated_at":"2024-09-20T05:33:46.000Z","dependencies_parsed_at":"2022-08-24T01:00:49.440Z","dependency_job_id":null,"html_url":"https://github.com/Fmstrat/shorten","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fmstrat%2Fshorten","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fmstrat%2Fshorten/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fmstrat%2Fshorten/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fmstrat%2Fshorten/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Fmstrat","download_url":"https://codeload.github.com/Fmstrat/shorten/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251559752,"owners_count":21609068,"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-11-11T22:15:44.126Z","updated_at":"2025-04-29T18:30:50.912Z","avatar_url":"https://github.com/Fmstrat.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Shorten\nShorten is an add-on app for ownCloud that enables one-click URL shortening. It's features include:\n- Automatic replacement of the public share URL with the shortened URL\n- No need to create a seperate \"Shorten\" URL\n- Internal shortner or goo.gl support\n- Ability to completely hide the ownCloud server with the internal shortener by proxying shortened requests through another server\n    - Note: While normal shares will never expose the ownCloud URL, password protected files will as the password display screen must be supplied to the user.\n\n## Installation\n\n### Step 1: Install the add-on\n\n- Place this app in *owncloud/apps/shorten* (Rename the extracted ZIP to \"shorten\" or you will receive errors)\n- Re-login to owncloud and run the update\n\n### Step 2: Setup the shortening server\n\n#### *Step 2 - Option A: goo.gl*\nTo use http://goo.gl, all you need to do is aquire an API key to use in the admin settings. You can aquire a key using these instructions from Google: *https://developers.google.com/url-shortener/v1/getting_started#APIKey*\n  \n#### *Step 2 - Option B: Internal shortener and privacy filter*\n\nNext, you must setup your shortening server. This can be the same webserver you are running ownCloud on, or a completely different server to enable a privacy filter for your owncloud installation. For the purpose of this guide, we will assume your setup is:\n- Your owncloud server is at *https://mylongdomain.ext:port/owncloud*\n- Your other, \"shortening\" server, is at *https://mydomain.ext*\n- You want your short URLs to be *https://mydomain.ext/s?SHORTCODE*\n\nTo accomplish this, you should copy the *REMOTE-HOST/index.php* to the remote host, however you wish. In this example we use scp:\n```\nmylongdomain ~# scp /var/www/owncloud/apps/shorten/REMOTE-HOST/index.php root@mydomain.ext:/var/www/s/index.php\n```\n\nNext, on the shortening server, edit the file to include your ownCloud server URL and set enabled to true:\n```\nmydomain ~# vi /var/www/s/index.php\n```\n```\n\u003c?php\n\n#\n# Enter your owncloud URL below with no trailing slash\n# Ex. \"https://mydomain.ext/owncloud\"\n#\n$owncloud_url = \"https://mylongdomain.ext:port/owncloud\";\n\n#\n# Set enabled to true when you are ready to use the application\n#\n$enabled = true;\n#$enabled = false;\n```\n\n### Step 3: Configure the app\n\nLastly, visit the administration page for ownCloud and in the *Shorten* configuration include your shortening server's URL, which is everything before *?SHORTCODE* if you are using the internal shortener. In this case:\n```\nhttps://mydomain.ext/s\n```\nIf you're using http://goo.gl, you would need to include your API key in the provided settings box.\n\nAt this point, when you check the box to share a file publically, the app will replace the public share link displayed in the ownCloud web interface.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffmstrat%2Fshorten","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffmstrat%2Fshorten","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffmstrat%2Fshorten/lists"}