WordPress应用程序密码用法

huangapple go评论46阅读模式
英文:

WordPress application pwd usage

问题

我正在尝试构建一个需要与WordPress应用共享用户的应用程序。我想要使用WordPress提供的REST API和应用程序密码功能。我对如何继续进行有些困惑。
首先,我将创建一个具有创建帐户权限的用户。
然后,我是否需要为每个用户创建一个应用程序密码?使用这些密码,用户会拥有与WordPress中相同的权限吗?
理想情况下,我想要有1个请求用于登录,1个用于注册,1个用于注销。

编辑:

似乎有多种身份验证WordPress的方式(jwt、OAuth、应用程序密码)。哪一种最适合移动应用程序的使用?哪一种提供了像以下这样的3个简单API调用:

  • 登录(电子邮件、密码)
  • 注册(电子邮件、用户名、密码)
  • 注销
英文:

I'm trying to build an app which needs to share users with a wordpress app. I want to use the REST api offered by wordpress and the application password feature. I'm a bit confused on how to proceed.
I will first create a users with permission to create account.
Then do I need to create a application password for each users? and with those password the user will have the same permission as in wordpress ?
Ideally I'ld like to have 1 request to login, 1 to register and 1 to logout.

Edit :

There seems to be multiple way to authenticate to wordpress (jwt, Oauth, app pwd). Which wants would fit the best for an mobile app usage. And which provide 3 simple api call like :

  • login (email, pwd)
  • register (email, username, pwd)
  • logout

答案1

得分: 0

我最终在WordPress上使用了miniOrange插件来设置JWT令牌登录。然后,对于注册,我创建了一个仅具有创建用户权限的帐户,然后我为该帐户添加了一个应用程序密码,并将其用于创建帐户。

英文:

So I ended up using miniOrange plugin on wordpress to set JWT token login. Then for the registration, I created an account with only permission to create users, then I added an application password to this account and I use it to create the accounts.

huangapple
  • 本文由 发表于 2023年5月28日 19:16:11
  • 转载请务必保留本文链接:https://go.coder-hub.com/76351204.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定