Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃摎 Documentation: Clarify when URL is optional in teams.createMembership() #635

Closed
2 tasks done
xuelink opened this issue Oct 9, 2023 · 4 comments 路 Fixed by appwrite/appwrite#8263
Closed
2 tasks done
Labels
bug Something isn't working documentation Improvements or additions to documentation

Comments

@xuelink
Copy link

xuelink commented Oct 9, 2023

馃憻 Reproduction steps

13.0.0 Release Note has

BREAKING - Parameter url is now optional in the createMembership endpoint

Even though the url is optional, it gives a url missing error.

teams.createMembership(
  teamId,
  ['owner'],
  undefined,
  userId
);

Linked issue:appwrite/appwrite#6839

Screenshot 2023-10-09 at 15 01 47

馃憤 Expected behavior

it may work or give another error like permission is not allowed.

馃憥 Actual Behavior

it gives URL is required error.

ERROR Error: Uncaught (in promise): AppwriteException: URL is required

馃幉 Appwrite version

Different version (specify in environment)

馃捇 Operating system

Linux

馃П Your Environment

sdk-web 13.0.0

馃憖 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

馃彚 Have you read the Code of Conduct?

@xuelink xuelink added the bug Something isn't working label Oct 9, 2023
@stnguyen90 stnguyen90 self-assigned this Oct 20, 2023
@stnguyen90
Copy link
Contributor

@behicsakar, thanks for raising this issue! 馃檹馃徏 The URL is only optional when calling the API using a server SDK (with API key). Looks like we need to update some docs to clarify that.

@stnguyen90 stnguyen90 transferred this issue from appwrite/sdk-for-web Oct 20, 2023
@stnguyen90 stnguyen90 assigned gewenyu99 and unassigned stnguyen90 Oct 20, 2023
@stnguyen90 stnguyen90 changed the title 馃悰 Bug Report: v13.0.0, Even though the url is optional, it gives url is required error. 馃悰 Bug Report: Clarify when URL is optional in teams.createMembership() Oct 20, 2023
@stnguyen90 stnguyen90 changed the title 馃悰 Bug Report: Clarify when URL is optional in teams.createMembership() 馃摎 Documentation: Clarify when URL is optional in teams.createMembership() Oct 20, 2023
@AnanyaJindal1145
Copy link

Hey @gewenyu99 ! Can I be assigned this issue?

@gewenyu99
Copy link
Contributor

@AnanyaJindal1145 You can take a shot at this :D

@eldadfux eldadfux transferred this issue from appwrite/appwrite Feb 19, 2024
@eldadfux eldadfux added the documentation Improvements or additions to documentation label Feb 19, 2024
@stnguyen90
Copy link
Contributor

Let's make the text:

URL to redirect the user back to your app from the invitation email. This parameter is not required when an API key is supplied. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an open redirect attack against your project API.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants