{"id":13253,"date":"2023-12-22T13:53:04","date_gmt":"2023-12-22T05:53:04","guid":{"rendered":"https:\/\/www.yimenyun.cn\/emen\/?p=13253"},"modified":"2023-12-22T13:53:04","modified_gmt":"2023-12-22T05:53:04","slug":"%e5%85%ac%e4%bc%97%e5%8f%b7%e7%bb%91%e5%ae%9a%e5%b0%8f%e7%a8%8b%e5%ba%8f%e5%bc%80%e5%8f%91%e5%b7%a5%e5%85%b7%e4%bb%8b%e7%bb%8d","status":"publish","type":"post","link":"https:\/\/www.yimenyun.cn\/emen\/13253\/","title":{"rendered":"\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u4ecb\u7ecd"},"content":{"rendered":"

\u968f\u7740\u5c0f\u7a0b\u5e8f\u7684\u5174\u8d77\uff0c\u8d8a\u6765\u8d8a\u591a\u7684\u4f01\u4e1a\u5f00\u59cb\u8003\u8651\u5c06\u81ea\u5df1\u7684\u4e1a\u52a1\u4ee5\u5c0f\u7a0b\u5e8f\u7684\u5f62\u5f0f\u5c55\u5c0f\u7a0b\u5e8f\u5c01\u88c5<\/a>\u73b0\u3002\u4f46\u662f\uff0c\u60f3\u8981\u5f00\u53d1\u5c0f\u7a0b\u5e8f\u5e76\u4e0d\u662f\u4e00\u4ef6\u5bb9\u6613\u7684\u4e8b\u60c5\uff0c\u5c24\u5176\u662f\u5bf9\u4e8e\u6ca1\u6709\u4e13\u4e1a\u5f00\u53d1\u7ecf\u9a8c\u7684\u4eba\u6765\u8bf4\u3002\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u5e94\u8fd0\u800c\u751f\uff0c\u6210\u4e3a\u4e86\u89e3\u51b3\u8fd9\u4e2a\u95ee\u9898\u7684\u65b9\u5f0f\u4e4b\u4e00\u3002<\/p>\n

\u516c\u4f17\u53f7\u662f\u6307\u5fae\u4fe1\u516c\u4f17\u5e73\u53f0\u4e2d\u7684\u516c\u4f17\u53f7\uff0c\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u5c31\u662f\u5c06\u516c\u4f17\u53f7\u548c\u5c0f\u7a0b\u5e8f\u8fdb\u884c\u7ed1\u5b9a\uff0c\u4ece\u800c\u53ef\u4ee5\u4f7f\u7528\u5fae\u4fe1\u516c\u4f17\u5e73\u53f0\u63d0\u4f9b\u7684\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u3002<\/p>\n

\u7ed1\u5b9a\u8fc7\u7a0b<\/p>\n

\u9996\u5148\u9700\u8981\u5728\u5fae\u4fe1\u516c\u4f17\u5e73\u53f0\u4e0a\u521b\u5efa\u5c0f\u7a0b\u5e8f\uff0c\u5e76\u83b7\u53d6\u5c0f\u7a0b\u5e8f\u7684 AppID \u548c AppSecret\u3002\u7136\u540e\u5728\u5c0f\u7a0b\u5e8f<\/p>\n

<\/figure>\n<\/p>\n

\u5f00\u53d1\u5de5\u5177\u4e2d\uff0c\u9009\u62e9\u201c\u5f00\u53d1->\u516c\u4f17\u53f7\u7ed1\u5b9a\u201d\uff0c\u8f93\u5165 AppID \u548c AppSecret\uff0c\u9a8c\u8bc1\u901a\u8fc7\u540e\uff0c\u5c31\u53ef\u4ee5\u5f00\u59cb\u7ed1\u5b9a\u64cd\u4f5c\u4e86\u3002<\/p>\n

\u9996\u5148\u9700\u8981\u5c06\u516c\u4f17\u53f7\u7684 AppID \u548c AppSecret \u586b\u5165\u8fd9\u91cc\uff0c\u7136\u540e\u70b9\u51fb\u201c\u9a8c\u8bc1\u5e76\u7ed1\u5b9a\u201d\u6309\u94ae\u3002\u5982\u679c\u9a8c\u8bc1\u901a\u8fc7\u4e86\uff0c\u5c31\u53ef\u4ee5\u770b\u5230\u4e00\u4e2a\u4e8c\u7ef4\u7801\uff0c\u5bf9\u5e94\u7684\u516c\u4f17\u53f7\u9700\u8981\u626b\u63cf\u8fd9\u4e2a\u4e8c\u7ef4\u7801\u3002\u626b\u63cf\u6210\u529f\u540e\uff0c\u516c\u4f17\u53f7\u4f1a\u4ee5\u7ba1\u7406\u5458\u8eab\u4efd\u4e0e\u5c0f\u7a0b\u5e8f\u7ed1\u5b9a\u8d77\u6765\uff0c\u8fd9\u65f6\u5019\u5c31\u53ef\u4ee5\u5728\u5fae\u4fe1\u516c\u4f17\u5e73\u53f0\u4e0a\uff0c\u4f7f\u7528\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u8fdb\u884c\u5f00\u53d1\u4e86\u3002<\/p>\n

\u7ed1\u5b9a\u539f\u7406<\/p>\n

\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\uff0c\u662f\u901a\u8fc7\u5fae\u4fe1\u5f00\u653e\u5e73\u53f0\u63d0\u4f9b\u7684\u6280\u672f\u5b9e\u73b0\u7684\u3002\u5b83\u53ef\u4ee5\u901a\u8fc7 OAuth2.0 \u6388\u6743\u673a\u5236\uff0c\u5b9e\u8df3\u8f6c\u5c0f\u7a0b\u5e8f<\/a>\u73b0\u516c\u4f17\u53f7\u4e0e\u5c0f\u7a0b\u5e8f\u7684\u7ed1\u5b9a\u3002OAuth2.0 \u662f\u4e00\u79cd\u5f00\u653e\u6807\u51c6\uff0c\u4e5f\u662f\u4e00\u79cd\u6388\u6743\u673a\u5236\uff0c\u76ee\u524d\u5e7f\u6cdb\u5e94\u7528\u4e8e\u5404\u7c7b\u7f51\u7ad9\u548c\u5e94\u7528\u7684\u6388\u6743\u8ba4\u8bc1\u4e2d\u3002<\/p>\n

\u5177\u4f53\u800c\u8a00\uff0cOAuth2.0 \u6388\u6743\u6d41\u7a0b\u5206\u4e3a\u56db\u6b65\uff1a<\/p>\n

1. \u7f51\u9875\u6388\u6743\u83b7\u53d6\u7528\u6237\u57fa\u672c\u4fe1\u606f<\/p>\n

\u516c\u4f17\u53f7\u53ef\u4ee5\u901a\u8fc7 OAuth2.0 \u673a\u5236\u83b7\u53d6\u7528\u6237\u57fa\u672c\u4fe1\u606f\uff0c\u4f46\u662f\u5728\u8fdb\u884c OAuth2.0 \u6388\u6743\u524d\uff0c\u9700\u8981\u5148\u83b7\u5f97\u7528\u6237\u7684\u6388\u6743\u540c\u610f\u3002\u5f53\u7528\u6237\u540c\u610f\u6388\u6743\u540e\uff0c\u516c\u4f17\u53f7\u5373\u53ef\u83b7\u5f97\u7528\u6237\u57fa\u672c\u4fe1\u606f\uff0c\u5305\u62ec\u7528\u6237\u7684\u6635\u79f0\u3001\u5934\u50cf\u3001\u57ce\u5e02\u7b49\u7b49\u3002<\/p>\n

2. \u83b7\u53d6 access_token<\/p>\n

\u5728\u4f7f\u7528\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\u65f6\uff0c\u9700\u8981\u7528\u5230 access_token\uff0caccess_token \u662f\u516c\u4f17\u53f7\u8c03\u7528\u5404\u63a5\u53e3\u65f6\u7684\u552f\u4e00\u51ed\u8bc1\uff0c\u4e5f\u662f\u83b7\u53d6\u5176\u4ed6\u5404\u79cd\u63a5\u53e3\u8c03\u7528\u51ed\u8bc1\u7684\u5fc5\u5907\u53c2\u6570\u3002<\/p>\n

3. \u8c03\u7528\u5fae\u4fe1\u5f00\u653e\u5e73\u53f0\u63a5\u53e3\u8fdb\u884c\u6388\u6743<\/p>\n

\u5728\u83b7\u53d6 access_token \u540e\uff0c\u516c\u4f17\u53f7\u53ef\u4ee5\u8c03\u7528\u5fae\u4fe1\u5f00\u653e\u5e73\u53f0\u63d0\u4f9b\u7684 API\uff0c\u8fdb\u884c\u6388\u6743\u7684\u64cd\u4f5c\u3002\u6388\u6743\u6210\u529f\u540e\uff0c\u516c\u4f17\u53f7\u5c31\u53ef\u4ee5\u4f7f\u7528\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u8fdb\u884c\u5f00\u53d1\u4e86\u3002<\/p>\n

4. \u5c06\u516c\u4f17\u53f7\u7ed1\u5b9a\u5230\u5c0f\u7a0b\u5e8f\u4e2d<\/p>\n

\u901a\u8fc7\u4e0a\u8ff0\u6d41\u7a0b\uff0c\u516c\u4f17\u53f7\u5c31\u53ef\u4ee5\u4f7f\u7528\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u8fdb\u884c\u5f00\u53d1\u4e86\u3002\u6b64\u65f6\uff0c\u516c\u4f17\u53f7\u4e0e\u5c0f\u7a0b\u5e8f\u5df2\u7ecf\u7ed1\u5b9a\u5728\u4e00\u8d77\uff0c\u53ef\u4ee5\u66f4\u65b9\u4fbf\u5730\u8fdb\u884c\u5c0f\u7a0b\u5e8f\u7684\u5f00\u53d1\u548c\u7ba1\u7406\u3002<\/p>\n

\u603b\u7ed3<\/p>\n

\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u662f\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u7684\u91cd\u8981\u9014\u5f84\u4e4b\u4e00\u3002\u901a\u8fc7\u5728\u5fae\u4fe1\u5f00\u653e\u5e73\u53f0\u4e0a\u8fdb\u884c\u6ce8\u518c\uff0c\u5e76\u5c06\u516c\u4f17\u53f7\u4e0e\u5c0f\u7a0b\u5e8f\u7ed1\u5b9a\u8d77\u6765\uff0c\u5c31\u53ef\u4ee5\u4f7f\u7528\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u8fdb\u884c\u5f00\u53d1\u548c\u7ba1\u7406\u3002\u638c\u63e1\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\u7684\u539f\u7406\u548c\u6d41\u7a0b\uff0c\u5bf9\u4e8e\u5f00\u53d1\u5c0f\u7a0b\u5e8f\u7684\u4eba\u5458\u6765\u8bf4\uff0c\u4f1a\u66f4\u52a0\u4fbf\u6377\u3002<\/p>\n

\u4e00\u95e8\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\uff08https:\/\/sapp.yimenapp.com\/\uff09\u662f\u4e00\u6b3e\u4e91\u7aef\u5316\u8de8\u5e73\u53f0\u5f00\u53d1\u5de5\u5177\uff0c\u53ef\u4ee5\u4e00\u952e\u5728\u7ebf\u5c06\u7f51\u7ad9\u6253\u5305\u6210\u5c0f\u7a0b\u5e8f\uff0c\u652f\u6301\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u3001\u652f\u4ed8\u5b9d\u5c0f\u7a0b\u5e8f\u3001\u6296\u97f3\u5c0f\u7a0b\u5e8f\u3001\u5feb\u624b\u5c0f\u7a0b\u5e8f\u3001\u767e\u5ea6\u5c0f\u7a0b\u5e8f\u7b49\u56fd\u5185\u4e3b\u6d41\u5c0f\u7a0b\u5e8f\u5e73\u53f0\u3002\u4e00\u95e8\u63d0\u4f9b100+\u5c0f\u7a0b\u5e8f\u539f\u751f\u63a5\u53e3\u81ea\u52a9\u8c03\u7528\uff0c\u5f00\u53d1\u8005\u53ea\u9700\u8981\u4f7f\u7528\u5f00\u53d1\u7f51\u7ad9\u7684\u80fd\u529b\u5373\u53ef\u5728\u7ebf\u5feb\u901f\u5236\u4f5c\u5c0f\u7a0b\u5e8f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"

\u968f\u7740\u5c0f\u7a0b\u5e8f\u7684\u5174\u8d77\uff0c\u8d8a\u6765\u8d8a\u591a\u7684\u4f01\u4e1a\u5f00\u59cb\u8003\u8651\u5c06\u81ea\u5df1\u7684\u4e1a\u52a1\u4ee5\u5c0f\u7a0b\u5e8f\u7684\u5f62\u5f0f\u5c55\u73b0\u3002\u4f46\u662f\uff0c\u60f3\u8981\u5f00\u53d1\u5c0f\u7a0b\u5e8f\u5e76\u4e0d\u662f\u4e00\u4ef6\u5bb9\u6613\u7684\u4e8b\u60c5\uff0c\u5c24\u5176\u662f\u5bf9\u4e8e\u6ca1\u6709\u4e13\u4e1a\u5f00\u53d1\u7ecf\u9a8c\u7684\u4eba\u6765\u8bf4\u3002\u516c\u4f17\u53f7\u7ed1\u5b9a\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u5de5\u5177\u5e94\u8fd0\u800c\u751f\uff0c\u6210\u4e3a\u4e86\u89e3\u51b3\u8fd9\u4e2a<\/p>\n","protected":false},"author":10,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[3893,6745,18024,89,484],"topic":[],"class_list":["post-13253","post","type-post","status-publish","format-standard","hentry","category-xcxkf","tag-3893","tag-6745","tag-appp","tag-89","tag-484"],"_links":{"self":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts\/13253","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/users\/10"}],"replies":[{"embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/comments?post=13253"}],"version-history":[{"count":1,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts\/13253\/revisions"}],"predecessor-version":[{"id":13294,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts\/13253\/revisions\/13294"}],"wp:attachment":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/media?parent=13253"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/categories?post=13253"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/tags?post=13253"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/topic?post=13253"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}