{"id":21467448,"url":"https://github.com/elusivecodes/fyreuri","last_synced_at":"2025-08-04T03:37:04.951Z","repository":{"id":62508484,"uuid":"433781186","full_name":"elusivecodes/FyreURI","owner":"elusivecodes","description":"FyreURI is a free, open-source URI library for PHP.","archived":false,"fork":false,"pushed_at":"2025-07-27T12:41:21.000Z","size":83,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-27T13:29:25.198Z","etag":null,"topics":["php","uri"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elusivecodes.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-12-01T10:27:44.000Z","updated_at":"2025-07-27T12:41:15.000Z","dependencies_parsed_at":"2024-04-12T12:26:29.649Z","dependency_job_id":"5b6dcfa4-c628-49b4-871a-610cabea6fad","html_url":"https://github.com/elusivecodes/FyreURI","commit_stats":null,"previous_names":[],"tags_count":29,"template":false,"template_full_name":null,"purl":"pkg:github/elusivecodes/FyreURI","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elusivecodes%2FFyreURI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elusivecodes%2FFyreURI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elusivecodes%2FFyreURI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elusivecodes%2FFyreURI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elusivecodes","download_url":"https://codeload.github.com/elusivecodes/FyreURI/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elusivecodes%2FFyreURI/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268644954,"owners_count":24283404,"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","status":"online","status_checked_at":"2025-08-04T02:00:09.867Z","response_time":79,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["php","uri"],"created_at":"2024-11-23T08:18:07.988Z","updated_at":"2025-08-04T03:37:04.921Z","avatar_url":"https://github.com/elusivecodes.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FyreURI\r\n\r\n**FyreURI** is a free, open-source immutable URI library for *PHP*.\r\n\r\n\r\n## Table Of Contents\r\n- [Installation](#installation)\r\n- [Basic Usage](#basic-usage)\r\n- [Methods](#methods)\r\n\r\n\r\n\r\n## Installation\r\n\r\n**Using Composer**\r\n\r\n```\r\ncomposer require fyre/uri\r\n```\r\n\r\nIn PHP:\r\n\r\n```php\r\nuse Fyre\\Http\\Uri;\r\n```\r\n\r\n## Basic Usage\r\n\r\n- `$uriString` is a string representing the uri.\r\n\r\n```php\r\n$uri = new Uri($uriString);\r\n```\r\n\r\nAlternatively, you can use the `fromString` method for easier chaining.\r\n\r\n```php\r\n$uri = Uri::fromString($uriString);\r\n```\r\n\r\n\r\n## Methods\r\n\r\n**Add Query**\r\n\r\nAdd a query parameter.\r\n\r\n- `$key` is a string representing the query key.\r\n- `$value` is the query value.\r\n\r\n```php\r\n$newUri = $uri-\u003eaddQuery($key, $value);\r\n```\r\n\r\n**Except Query**\r\n\r\nRemove query parameters.\r\n\r\n- `$keys` is an array containing the query parameters to remove.\r\n\r\n```php\r\n$newUri = $uri-\u003eexceptQuery($keys);\r\n```\r\n\r\n**Get Authority**\r\n\r\nGet the URI authority string.\r\n\r\n```php\r\n$authority = $uri-\u003egetAuthority();\r\n```\r\n\r\n**Get Fragment**\r\n\r\nGet the URI fragment.\r\n\r\n```php\r\n$fragment = $uri-\u003egetFragment();\r\n```\r\n\r\n**Get Host**\r\n\r\nGet the URI host.\r\n\r\n```php\r\n$host = $uri-\u003egetHost();\r\n```\r\n\r\n**Get Path**\r\n\r\nGet the URI path.\r\n\r\n```php\r\n$path = $uri-\u003egetPath();\r\n```\r\n\r\n**Get Port**\r\n\r\nGet the URI port.\r\n\r\n```php\r\n$port = $uri-\u003egetPort();\r\n```\r\n\r\n**Get Query**\r\n\r\nGet the URI query array.\r\n\r\n```php\r\n$query = $uri-\u003egetQuery();\r\n```\r\n\r\n**Get Query String**\r\n\r\nGet the URI query string.\r\n\r\n```php\r\n$query = $uri-\u003egetQueryString();\r\n```\r\n\r\n**Get Scheme**\r\n\r\nGet the URI scheme.\r\n\r\n```php\r\n$scheme = $uri-\u003egetScheme();\r\n```\r\n\r\n**Get Segment**\r\n\r\nGet a specified URI segment.\r\n\r\n- `$segment` is a number indicating the segment index.\r\n\r\n```php\r\n$part = $uri-\u003egetSegment($segment);\r\n```\r\n\r\n**Get Segments**\r\n\r\nGet the URI segments.\r\n\r\n```php\r\n$segments = $uri-\u003egetSegments();\r\n```\r\n\r\n**Get Total Segments**\r\n\r\nGet the URI segments count.\r\n\r\n```php\r\n$segmentCount = $uri-\u003egetTotalSegments();\r\n```\r\n\r\n**Get Uri**\r\n\r\nGet the URI string.\r\n\r\n```php\r\n$uriString = $uri-\u003egetUri();\r\n```\r\n\r\n**Get User Info**\r\n\r\nGet the user info string.\r\n\r\n```php\r\n$userInfo = $uri-\u003egetUserInfo();\r\n```\r\n\r\n**Only Query**\r\n\r\nFilter query parameters.\r\n\r\n- `$keys` is an array containing the query parameters to keep.\r\n\r\n```php\r\n$newUri = $uri-\u003eonlyQuery($keys);\r\n```\r\n\r\n**Set Authority**\r\n\r\nSet the URI authority string.\r\n\r\n- `$authority` is a string representing the authority.\r\n\r\n```php\r\n$newUri = $uri-\u003esetAuthority($authority);\r\n```\r\n\r\n**Set Fragment**\r\n\r\nSet the URI fragment.\r\n\r\n- `$fragment` is a string representing the fragment.\r\n\r\n```php\r\n$newUri = $uri-\u003esetFragment($fragment);\r\n```\r\n\r\n**Set Host**\r\n\r\nSet the URI host.\r\n\r\n- `$host` is a string representing the host.\r\n\r\n```php\r\n$newUri = $uri-\u003esetHost($host);\r\n```\r\n\r\n**Set Path**\r\n\r\nSet the URI path.\r\n\r\n- `$path` is a string representing the path.\r\n\r\n```php\r\n$newUri = $uri-\u003esetPath($path);\r\n```\r\n\r\n**Set Port**\r\n\r\nGet the URI port.\r\n\r\n- `$port` is a number representing the port.\r\n\r\n```php\r\n$newUri = $uri-\u003esetPort($port);\r\n```\r\n\r\n**Set Query**\r\n\r\nGet the URI query array.\r\n\r\n- `$query` is an array containing the query parameters.\r\n\r\n```php\r\n$newUri = $uri-\u003esetQuery($query);\r\n```\r\n\r\n**Set Query String**\r\n\r\nGet the URI query string.\r\n\r\n- `$query` is a string representing the query parameters.\r\n\r\n```php\r\n$newUri = $uri-\u003esetQueryString($query);\r\n```\r\n\r\n**Set Scheme**\r\n\r\nGet the URI scheme.\r\n\r\n- `$scheme` is a string representing the scheme.\r\n\r\n```php\r\n$newUri = $uri-\u003esetScheme($scheme);\r\n```\r\n\r\n**Set User Info**\r\n\r\nGet the user info string.\r\n\r\n- `$username` is a string representing the username.\r\n- `$password` is a string representing the password, and will default to *\"\"*.\r\n\r\n```php\r\n$newUri = $uri-\u003esetUserInfo($username, $password);\r\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felusivecodes%2Ffyreuri","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felusivecodes%2Ffyreuri","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felusivecodes%2Ffyreuri/lists"}