Skip to content

Avoid percent-encoding for "(" and ")" characters. - #37

Open
Powerbyte7 wants to merge 1 commit into
vrchatapi:mainfrom
Powerbyte7:fix-encoding
Open

Avoid percent-encoding for "(" and ")" characters.#37
Powerbyte7 wants to merge 1 commit into
vrchatapi:mainfrom
Powerbyte7:fix-encoding

Conversation

@Powerbyte7

Copy link
Copy Markdown

The VRChat API does not accept percent-encoded variants of InstanceID, specifically the characters "(" and ")". This causes an error when attempting the following API call:

https://api.vrchat.cloud/api/1/instances/wrld_28aab3e4-953f-4c85-9223-ef29a0873a6e:31124%7Egroup%28grp_b2a19685-c53e-4c5a-9503-744a5373bf2c%29%7EgroupAccessType%28plus%29%7Eregion%28use%29/shortName
{"error":{"message":"\"malformed url\"","status_code":400,"waf_code":26497}}

When using the raw string without encoding, the API yields a 200 response as expected.

https://vrchat.com/api/1/instances/wrld_28aab3e4-953f-4c85-9223-ef29a0873a6e:31124~group(grp_b2a19685-c53e-4c5a-9503-744a5373bf2c)~groupAccessType(plus)~region(use)/shortName

See vrchatapi/vrchatapi-rust#43 for more details.

The VRChat API does not accept percent-encoded variants of InstanceID, specifically the characters "(" and ")". This causes an error when attempting the following API call:
```
https://api.vrchat.cloud/api/1/instances/wrld_28aab3e4-953f-4c85-9223-ef29a0873a6e:31124%7Egroup%28grp_b2a19685-c53e-4c5a-9503-744a5373bf2c%29%7EgroupAccessType%28plus%29%7Eregion%28use%29/shortName
```
```json
{"error":{"message":"\"malformed url\"","status_code":400,"waf_code":26497}}
```
When using the raw string without encoding, the API yields a `200` response as expected.
```
https://vrchat.com/api/1/instances/wrld_28aab3e4-953f-4c85-9223-ef29a0873a6e:31124~group(grp_b2a19685-c53e-4c5a-9503-744a5373bf2c)~groupAccessType(plus)~region(use)/shortName
```
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@Powerbyte7