{"id":350687,"date":"2023-07-24T09:00:59","date_gmt":"2023-07-24T09:00:59","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=350687"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=350687","title":{"rendered":"<span>Web Services \u0432 Joomla 4<\/span>"},"content":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p>\u042d\u0442\u043e\u0442 \u0442\u0435\u043a\u0441\u0442 &#8212;\u00a0<a href=\"https:\/\/manual.joomla.org\/docs\/general-concept\/webservices\" rel=\"noopener noreferrer nofollow\">\u043f\u0435\u0440\u0435\u0432\u043e\u0434\u00a0<\/a>\u0441\u0442\u0430\u0442\u044c\u0438 \u0438\u0437\u00a0<a href=\"https:\/\/manual.joomla.org\/\" rel=\"noopener noreferrer nofollow\">\u043d\u043e\u0432\u043e\u0433\u043e \u043f\u043e\u0440\u0442\u0430\u043b\u0430 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u0434\u043b\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 Joomla<\/a>, \u0440\u0430\u0437\u0434\u0435\u043b &#171;\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0438&#187;. \u0420\u0430\u043d\u0435\u0435 \u0443\u0436\u0435 \u0431\u044b\u043b \u043e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u0440\u0430\u0437\u0434\u0435\u043b\u0430, \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u044e\u0449\u0435\u0433\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u044b <a href=\"https:\/\/habr.com\/ru\/articles\/692342\/\" rel=\"noopener noreferrer nofollow\">Dependency Injection Containers \u0432 Joomla 4<\/a>.<\/p>\n<hr\/>\n<h2>\u041a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u044f \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432<\/h2>\n<ul>\n<li>\n<p>\u0412\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u0434\u043b\u044f \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c \u0434\u0440\u0443\u0433 \u0441 \u0434\u0440\u0443\u0433\u043e\u043c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0430 HTTP, \u0430 \u0432 \u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0435\u0435 \u0432\u0440\u0435\u043c\u044f \u0438 \u0447\u0435\u0440\u0435\u0437 TLS (\u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u044c \u0442\u0440\u0430\u043d\u0441\u043f\u043e\u0440\u0442\u043d\u043e\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f).<\/p>\n<\/li>\n<li>\n<p>\u0412\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u044b \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u044e\u0442 \u043a\u0430\u043a \u043a\u043e\u043d\u0442\u0440\u0430\u043a\u0442 \u043c\u0435\u0436\u0434\u0443 \u043f\u043e\u0441\u0442\u0430\u0432\u0449\u0438\u043a\u043e\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438 \u043f\u043e\u0442\u0440\u0435\u0431\u0438\u0442\u0435\u043b\u0435\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0447\u0435\u0440\u0435\u0437 Endpoint. <\/p>\n<\/li>\n<li>\n<p>\u0412\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u044b \u043f\u043e\u0434\u043e\u0431\u043d\u044b \u0434\u0432\u0435\u0440\u044f\u043c \u0438 \u043e\u043a\u043d\u0430\u043c \u0432 \u0434\u043e\u043c\u0435, \u043e\u043d\u0438 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0412\u0425\u041e\u0414\u0410\u041c\u0418 (inputs) \u0438 \u0412\u042b\u0425\u041e\u0414\u0410\u041c\u0418 (outputs) \u0432\u043e \u0412\u041d\u0415\u0428\u041d\u0418\u0419 \u043c\u0438\u0440.<\/p>\n<\/li>\n<li>\n<p>\u0412 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435 Joomla \u043a\u0430\u043a \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0432 \u0446\u0435\u043b\u043e\u043c, Joomla Web services API \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 Joomla \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u0441 \u0432\u043d\u0435\u0448\u043d\u0438\u043c\u0438 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430\u043c\u0438 \u0434\u0430\u043d\u043d\u044b\u0445. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u0435\u0431-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438, \u043c\u043e\u0431\u0438\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438 \u0438 \u0442.\u0434.<\/p>\n<\/li>\n<\/ul>\n<h2>\u0412\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0441 Web Services API Joomla 4.x<\/h2>\n<p>\u0412\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0441 API \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 Joomla 4 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0447\u0435\u0440\u0435\u0437 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u0435 endpoint&#8217;\u044b:<\/p>\n<ul>\n<li>\n<p><a href=\"https:\/\/docs.joomla.org\/J4.x:Joomla_Core_APIs\" rel=\"noopener noreferrer nofollow\">\u0421\u043f\u0438\u0441\u043e\u043a endpoint&#8217;\u043e\u0432 \u044f\u0434\u0440\u0430 Joomla<\/a> (\u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f Joomla)<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/github.com\/alexandreelise\/j4x-api-collection\" rel=\"noopener noreferrer nofollow\">\u041a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044f Joomla endpoints \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 Postman<\/a> (GitHub)<\/p>\n<\/li>\n<\/ul>\n<h2>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 Joomla API<\/h2>\n<p>\u0427\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e, \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 Joomla API, \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u043f\u043e-\u043f\u0440\u0435\u0436\u043d\u0435\u043c\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f cURL \u0438\u043b\u0438 php. \u0427\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e cURL \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u043d\u0430 \u0412\u0430\u0448\u0435\u043c \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435. \u0412 \u043f\u0440\u043e\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <code>phpinfo();<\/code> <\/p>\n<h3>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435<\/h3>\n<p>\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u043c\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u043e \u0432\u0441\u0435\u0445 \u043d\u0430\u0448\u0438\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u0430\u0445:<\/p>\n<ul>\n<li>\n<p>URL \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430 \u043d\u0430 Joomla 4.x<\/p>\n<\/li>\n<li>\n<p>\u0422\u043e\u043a\u0435\u043d Joomla API \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438 \u0441\u0443\u043f\u0435\u0440\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438\u043b\u0438 \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438, \u0443 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0435\u0441\u0442\u044c, \u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435, \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 <code>core.login.api<\/code> \u0438 <code>core.login.site<\/code>, \u0447\u0442\u043e\u0431\u044b \u0438\u043c\u0435\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u0438\u0434\u0435\u0442\u044c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0442\u043e\u043a\u0435\u043d\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u0432\u043e\u0448\u0435\u0434\u0448\u0435\u0433\u043e \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0443.<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  \/\/ \u041f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u0435 \u0412\u0430\u0448 \u0442\u043e\u043a\u0435\u043d Joomla! Api token \u0432 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0435 \u043c\u0435\u0441\u0442\u043e, \/\/ \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 \u0438\u043b\u0438 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435. \/\/ \u041c\u044b \u043d\u0435 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \/\/ \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043f\u0430\u0440\u043e\u043b\u0435\u0439. \/\/ \u0417\u0434\u0435\u0441\u044c \u043e\u043f\u0438\u0441\u0430\u043d\u043e \u043f\u043e\u0447\u0435\u043c\u0443: https:\/\/www.trendmicro.com\/en_us\/research\/22\/h\/analyzing-hidden-danger-of-environment-variables-for-keeping-secrets.html  $token = '';<\/code><\/pre>\n<p>[<a href=\"https:\/\/habr.com\/ru\/articles\/568996\/\" rel=\"noopener noreferrer nofollow\">\u0421\u0442\u0430\u0442\u044c\u044f \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0432\u043d\u0435\u0448\u043d\u0438\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c HttpFactory (Joomla) \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 &#8212; \u0422.\u0421.<\/a>]<\/p>\n<p>\u041f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u0435 \u0412\u0430\u0448 \u0442\u043e\u043a\u0435\u043d Joomla! Api token \u0432 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0435 \u043c\u0435\u0441\u0442\u043e, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 \u0438\u043b\u0438 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435. \u041c\u044b \u043d\u0435 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f  \u043f\u0430\u0440\u043e\u043b\u0435\u0439. \u0417\u0434\u0435\u0441\u044c \u043e\u043f\u0438\u0441\u0430\u043d\u043e \u043f\u043e\u0447\u0435\u043c\u0443 &#8212; \u0441\u0442\u0430\u0442\u044c\u044f &#171;<a href=\"https:\/\/www.trendmicro.com\/en_us\/research\/22\/h\/analyzing-hidden-danger-of-environment-variables-for-keeping-secrets.html\" rel=\"noopener noreferrer nofollow\">Analyzing the Hidden Danger of Environment Variables for Keeping Secrets<\/a>&#187; \u043d\u0430 TrendMicro.com.<\/p>\n<h3>POST &#8212; \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u0432 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 &#171;Uncategorized&#187; (&#171;\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438&#187;) \u043f\u043e REST API (ID \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 = 2)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = '';  $categoryId = 2; \/\/ \u041a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u044f \"\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438\" Joomla \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e  $data = [ 'title'       => '\u041a\u0430\u043a \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b Joomla \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e REST API?', 'alias'       => '\u043aak-dobavit-material-joomla-s-pomoshhju-rest-api', 'articletext' => '\u042f \u043f\u043e\u043a\u0430 \u043d\u0435 \u0437\u043d\u0430\u044e... \u041f\u043e\u0438\u0449\u0443-\u043a\u0430 \u044f \u043d\u043e\u0432\u0435\u043d\u044c\u043a\u0438\u0435 \u0441\u0442\u0430\u0442\u044c\u0438 \u043e Joomla \u043d\u0430 \u0425\u0430\u0431\u0440\u0435.', 'catid'       => $categoryId, 'language'    => '*', 'metadesc'    => '', 'metakey'     => '', ];  $dataString = json_encode($data);  \/\/ HTTP request headers $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', 'Content-Length: ' . mb_strlen($dataString), sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0435 endpoint \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430\u043c\u0438. \/\/ \u042d\u0442\u043e \u0447\u0430\u0441\u0442\u044c $uri. $uri->setPath('content\/articles');  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('POST', $uri, $dataString, $headers, $timeout);  \/\/ \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043c\u044b \u0438\u043c\u0435\u0435\u043c stream, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0435\u043b\u0430\u0435\u043c \u043f\u0440\u043e\u0441\u0442\u043e: echo $response->body;<\/code><\/pre>\n<h3>\u041d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u043e\u0442\u0441\u0442\u0443\u043f\u043b\u0435\u043d\u0438\u0435 \u043e \u043a\u043b\u0430\u0441\u0441\u0435 Uri \u0432 Joomla (\u043e\u0442 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430)<\/h3>\n<p>\u0414\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0435\u0433\u043e \u043f\u043e\u043d\u0438\u043c\u0430\u043d\u0438\u044f \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u044f\u0449\u0435\u0433\u043e \u0432 \u043a\u043e\u0434\u0435 \u0438 \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0439 \u0431\u043e\u043b\u0435\u0435 \u0443\u0434\u043e\u0431\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 Joomla API \u043f\u043e\u0437\u0432\u043e\u043b\u044e \u0441\u0435\u0431\u0435 \u0432\u043d\u0435\u0434\u0440\u0438\u0442\u044c \u043a\u0440\u0430\u0442\u043a\u0443\u044e \u0441\u043f\u0440\u0430\u0432\u043a\u0443 \u043e \u043a\u043b\u0430\u0441\u0441\u0430\u0445 Uri \u0432 Joomla:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/7f5\/5ef\/82b\/7f55ef82b7eddb68badf3e446ca7c14d.png\" width=\"848\" height=\"190\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7f5\/5ef\/82b\/7f55ef82b7eddb68badf3e446ca7c14d.png\"\/><\/figure>\n<ul>\n<li>\n<p><a href=\"https:\/\/docs.joomla.org\/URLs_in_Joomla\" rel=\"noopener noreferrer nofollow\">\u041e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f Joomla \u043f\u043e \u043a\u043b\u0430\u0441\u0441\u0443 Joomla\\Uri\\Uri<\/a><\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u043a\u0438 \u0434\u043b\u044f Joomla 3, \u043d\u043e \u043a\u043b\u0430\u0441\u0441 Uri \u0432 Joomla 4 \u043e\u0441\u0442\u0430\u043b\u0441\u044f \u0432 \u0446\u0435\u043b\u043e\u043c \u0442\u0435\u043c \u0436\u0435. <\/p>\n<\/li>\n<li>\n<p>\u0412 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u043f\u043e \u0441\u0441\u044b\u043b\u043a\u0435 \u0443\u043a\u0430\u0437\u0430\u043d \u043a\u043b\u0430\u0441\u0441 <code>Joomla\\CMS\\Uri\\Uri<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u0442 \u043a\u043b\u0430\u0441\u0441 <code>Joomla\\Uri\\Uri<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432 \u0441\u0432\u043e\u044e \u043e\u0447\u0435\u0440\u0435\u0434\u044c, \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u0442 \u043a\u043b\u0430\u0441\u0441 <code>Joomla\\Uri\\AbstractUri<\/code>. \u041c\u0435\u0442\u043e\u0434\u044b \u0440\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u0432 \u0434\u043e\u0447\u0435\u0440\u043d\u0435\u043c.<\/p>\n<\/li>\n<li>\n<p>\u041a\u043b\u0430\u0441\u0441 <code>Joomla\\Uri\\Uri<\/code> \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 url \u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u043d\u0438\u043c \u043a\u0430\u043a \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c: <code>$url->setPath<\/code>, <code>$url->setScheme<\/code>, <code>$url->setScheme<\/code> , <code>$url->setScheme<\/code> \u0438 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043c\u0435\u0442\u043e\u0434\u0430\u043c\u0438 (\u0441\u043f\u0438\u0441\u043e\u043a \u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432 \u0444\u0430\u0439\u043b\u0435 \u043a\u043b\u0430\u0441\u0441\u0430: <em>libraries\/vendor\/joomla\/uri\/src\/Uri.php<\/em>). \u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0433\u0435\u0442\u0442\u0435\u0440\u044b \u0437\u0430\u0434\u0430\u043d\u044b \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 <code>Joomla\\Uri\\AbstractUri<\/code><\/p>\n<\/li>\n<li>\n<p>\u041a\u043b\u0430\u0441\u0441 <code>Joomla\\CMS\\Uri\\Uri<\/code> \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043c\u0435\u0442\u043e\u0434\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0435 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0435\u0439 \u0440\u0430\u0431\u043e\u0442\u044b Joomla: \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0432\u043d\u0435\u0448\u043d\u0438\u0439 \u043b\u0438 \u0438\u043b\u0438 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u0439 url, \u0442\u0435\u043a\u0443\u0449\u0438\u0439 url \u0431\u0435\u0437 GET-\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0438 \u0442.\u0434.<\/p>\n<\/li>\n<\/ul>\n<h3>GET &#8212; \u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u0432\u0441\u0435\u0445 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 Joomla \u0438\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 &#171;Uncategorized&#187; (&#171;\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438&#187;)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = '';  $categoryId = 2; \/\/ \u041a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u044f \"\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438\" Joomla \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e  \/\/ \u041d\u0435 \u0431\u0443\u0434\u0435\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c payload \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 $dataString = null;  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0435 endpoint \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430\u043c\u0438. \/\/ \u042d\u0442\u043e \u0447\u0430\u0441\u0442\u044c $uri. $uri->setPath('content\/articles');  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('GET', $uri, $dataString, $headers, $timeout);  \/\/ \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043c\u044b \u0438\u043c\u0435\u0435\u043c stream, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0435\u043b\u0430\u0435\u043c \u043f\u0440\u043e\u0441\u0442\u043e: echo $response->body;<\/code><\/pre>\n<h3>GET &#8212; \u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = '';  $articleId = 1; \/\/ ID \u043d\u0443\u0436\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u0432 Joomla  \/\/ \u041d\u0435 \u0431\u0443\u0434\u0435\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c payload \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 $dataString = null;  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c path-\u0447\u0430\u0441\u0442\u044c Url \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430. $uri->setPath(sprintf('content\/articles\/%d', $articleId));  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('GET', $uri, $dataString, $headers, $timeout);  \/\/ \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043c\u044b \u0438\u043c\u0435\u0435\u043c stream, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0435\u043b\u0430\u0435\u043c \u043f\u0440\u043e\u0441\u0442\u043e: echo $response->body;<\/code><\/pre>\n<h3>PATCH &#8212; \u0418\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = ''; $articleId = 1; \/\/ ID \u043d\u0443\u0436\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u0432 Joomla  $data = [ 'id'          => $articleId, 'title'       => '\u041a\u0430\u043a \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b Joomla \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e REST API?', 'introtext' => '\u041f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 PATCH \u0442\u0435\u043a\u0441\u0442 \u0441\u0442\u0430\u0442\u044c\u0438 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0440\u0430\u0437\u0434\u0435\u043b\u0435\u043d \u043d\u0430 \u0434\u0432\u0435 \u0447\u0430\u0441\u0442\u0438 \u0438\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c, \u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435, \u0442\u043e\u043b\u044c\u043a\u043e introtext, \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043e\u043b\u0436\u043d\u044b\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c', 'fulltext' => '\u0411\u043e\u043b\u044c\u0448\u0435 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430 \u0431\u043e\u0433\u0443 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430!', ];  $dataString = json_encode($data);  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', 'Content-Length: ' . mb_strlen($dataString), sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c path-\u0447\u0430\u0441\u0442\u044c Url \u0434\u043b\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430. $uri->setPath(sprintf('content\/articles\/%d', $articleId));  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('PATCH', $uri, $dataString, $headers, $timeout);  \/\/ \u0417\u0434\u0435\u0441\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u043c status code \u0437\u0430\u043f\u0440\u043e\u0441\u0430 echo $response->code;<\/code><\/pre>\n<h4>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430 \u043e \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0435 \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0438 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla<\/h4>\n<p><em>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430 \u0434\u043b\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432, \u043d\u0435 \u0437\u043d\u0430\u043a\u043e\u043c\u044b\u0445 \u0441\u043e \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u043e\u0439 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 (com_content) Joomla. \u041a\u0430\u0436\u0434\u044b\u0439 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b (article) \u0438\u043c\u0435\u0435\u0442 \u0432\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442 \u0438 \u0432\u0432\u043e\u0434\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442. \u0412\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442\u0441\u044f \u0432 \u0441\u043f\u0438\u0441\u043a\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 \u0432 \u0432\u0438\u0434\u0435 \u0431\u043b\u043e\u0433\u0430 (\u0441 \u043a\u0430\u0440\u0442\u0438\u043d\u043a\u043e\u0439 \u0432\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0442\u0435\u043a\u0441\u0442\u0430, \u043f\u0430\u0440\u043e\u0439 \u0430\u0431\u0437\u0430\u0446\u0435\u0432 \u0438 \u043a\u043d\u043e\u043f\u043a\u043e\u0439 &#171;\u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435&#187;). \u041f\u043e\u043b\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442\u0441\u044f, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043a\u043e\u0433\u0434\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0445\u043e\u0447\u0435\u0442 \u0447\u0438\u0442\u0430\u0442\u044c \u0441\u0442\u0430\u0442\u044c\u044e \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0438 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u0442 \u0435\u0451. <\/em><\/p>\n<p><em>\u0412 \u0431\u0430\u0437\u0435 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 \u0442\u0430\u0431\u043b\u0438\u0446\u0435 \u0434\u043b\u044f \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 Joomla \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043e 2 \u044f\u0447\u0435\u0439\u043a\u0438: <\/em><strong><em>introtext<\/em><\/strong><em> \u0438 <\/em><strong><em>fulltext<\/em><\/strong><em> \u0442\u0438\u043f\u0430 <\/em><strong><em>MEDIUMTEXT<\/em><\/strong><em> \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e. <\/em><\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/737\/95e\/f9d\/73795ef9d98538d890a14afae3c05705.png\" width=\"857\" height=\"618\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/737\/95e\/f9d\/73795ef9d98538d890a14afae3c05705.png\"\/><\/figure>\n<p><em>\u0415\u0441\u043b\u0438 \u043a\u043e\u043d\u0442\u0435\u043d\u0442-\u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0432\u0441\u0442\u0430\u0432\u043a\u0438 \u043b\u0438\u043d\u0438\u0438 &#171;\u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435&#187; \u0432 \u0430\u0434\u043c\u0438\u043d\u043a\u0435 \u0443\u043a\u0430\u0437\u0430\u043b Joomla, \u0447\u0442\u043e \u0442\u0435\u043a\u0441\u0442 \u043d\u0443\u0436\u043d\u043e \u0440\u0430\u0437\u0431\u0438\u0442\u044c \u043d\u0430 \u0432\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u0443\u044e \u0438 \u043f\u043e\u043b\u043d\u0443\u044e \u0447\u0430\u0441\u0442\u044c, \u0442\u043e \u0442\u0435\u043a\u0441\u0442 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0437\u0440\u0435\u0437\u0430\u043d \u043d\u0430 2 \u0447\u0430\u0441\u0442\u0438 \u0438 \u043a\u0430\u0436\u0434\u0430\u044f \u0438\u0437 \u0447\u0430\u0441\u0442\u0435\u0439 \u0431\u0443\u0434\u0435\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u044c\u0441\u044f \u0432 \u0441\u0432\u043e\u0435\u0439 \u044f\u0447\u0435\u0439\u043a\u0435.  \u0415\u0441\u043b\u0438 \u0436\u0435 \u043b\u0438\u043d\u0438\u044f &#171;\u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435&#187; \u043d\u0435 \u0432\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0430, \u0442\u043e \u0432\u0435\u0441\u044c \u0442\u0435\u043a\u0441\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u0441\u044f \u0432 \u044f\u0447\u0435\u0439\u043a\u0435 <\/em><strong><em>introtext<\/em><\/strong><em>.<\/em><\/p>\n<p><em>\u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043f\u0440\u0438 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441 REST API \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0442\u044c \u041a\u0410\u041a \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0440\u0430\u0431\u043e\u0442\u0430 \u0441 \u0442\u0435\u043a\u0441\u0442\u043e\u043c \u043d\u0430 \u0432\u0441\u0435\u0445 \u044d\u0442\u0430\u043f\u0430\u0445: \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435, \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0443, \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0441\u0430\u0439\u0442\u0430. \u0415\u0441\u043b\u0438 Joomla \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0431\u044d\u043a\u0435\u043d\u0434, \u0430 \u0444\u0440\u043e\u043d\u0442 &#8212; \u044d\u0442\u043e \u043c\u043e\u0431\u0438\u043b\u044c\u043d\u043e\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0438\u043b\u0438 \u0444\u0440\u043e\u043d\u0442 \u0441\u0434\u0435\u043b\u0430\u043d \u043d\u0430 js-\u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0435, \u0442\u043e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u0443\u0436\u0435 \u043d\u0435 \u043e\u0442 Joomla, \u0430 \u043e\u0442 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0438 \u0442\u043e\u0433\u0434\u0430 \u0432\u0435\u0441\u044c \u0442\u0435\u043a\u0441\u0442 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 \u043c\u043e\u0436\u043d\u043e \u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0432 introtext. \u0415\u0441\u043b\u0438 \u0436\u0435 REST API \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438, \u0430 \u0434\u043b\u044f \u043f\u043e\u0441\u0435\u0442\u0438\u0442\u0435\u043b\u0435\u0439 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f HTML-\u0432\u044b\u0432\u043e\u0434 Joomla, \u0442\u043e \u0441\u043e\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u0435 \u043f\u0440\u0430\u0432\u0438\u043b \u0438\u0433\u0440\u044b CMS \u0431\u0443\u0434\u0435\u0442 \u0432\u0430\u0436\u043d\u044b\u043c, \u0442\u0430\u043a \u043a\u0430\u043a \u044d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u0432\u043b\u0438\u044f\u0442\u044c \u043d\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0434\u043b\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u0441\u0430\u0439\u0442\u0430.<\/em> <\/p>\n<h3>DELETE &#8212; \u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = ''; $articleId = 1; \/\/ ID \u043d\u0443\u0436\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u0432 Joomla  \/\/ \u041d\u0435 \u0431\u0443\u0434\u0435\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c payload \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 $dataString = null;  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c path-\u0447\u0430\u0441\u0442\u044c Url \u0434\u043b\u044f \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430. $uri->setPath(sprintf('content\/articles\/%d', $articleId));  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('DELETE', $uri, $dataString, $headers, $timeout);  \/\/ \u0417\u0434\u0435\u0441\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u043c status code \u0437\u0430\u043f\u0440\u043e\u0441\u0430 echo $response->code;<\/code><\/pre>\n<h2>\u0417\u0430\u043f\u0440\u043e\u0441\u044b \u043a REST API Joomla \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0447\u0438\u0441\u0442\u043e\u0433\u043e PHP cURL <\/h2>\n<p>\u041f\u0435\u0440\u0435\u0434 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u044d\u0442\u043e\u0433\u043e \u043a\u043e\u0434\u0430 \u0443\u0434\u043e\u0441\u0442\u043e\u0432\u0435\u0440\u044c\u0442\u0435\u0441\u044c, \u0447\u0442\u043e cURL \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d \u043d\u0430 \u0412\u0430\u0448\u0435\u043c \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435, \u043f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <code>phpinfo()<\/code>. [<em>\u0414\u0430\u043d\u043d\u044b\u0439 \u0440\u0430\u0437\u0434\u0435\u043b \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u0438\u0433\u043e\u0434\u0438\u0442\u0441\u044f \u0434\u043b\u044f non-Joomla \u0441\u0430\u0439\u0442\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u0441 Joomla 4+ \u0441\u0430\u0439\u0442\u0430\u043c\u0438 &#8212; \u0422.\u0421.<\/em>]<\/p>\n<h3>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435<\/h3>\n<p>\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u043c\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u043e \u0432\u0441\u0435\u0445 \u043d\u0430\u0448\u0438\u0445 cURL\u00a0 \u0437\u0430\u043f\u0440\u043e\u0441\u0430\u0445:<\/p>\n<ul>\n<li>\n<p>URL \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430 \u043d\u0430 Joomla 4.x<\/p>\n<\/li>\n<li>\n<p>\u0422\u043e\u043a\u0435\u043d Joomla API \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438 \u0441\u0443\u043f\u0435\u0440\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438\u043b\u0438 \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438, \u0443 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0435\u0441\u0442\u044c, \u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435, \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 <code>core.login.api<\/code> \u0438 <code>core.login.site<\/code>, \u0447\u0442\u043e\u0431\u044b \u0438\u043c\u0435\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u0438\u0434\u0435\u0442\u044c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0442\u043e\u043a\u0435\u043d\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u0432\u043e\u0448\u0435\u0434\u0448\u0435\u0433\u043e \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0443.<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL $curl  = curl_init();  $url   = 'https:\/\/example.org\/api\/index.php\/v1';  \/\/ \u041f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u0435 \u0412\u0430\u0448 \u0442\u043e\u043a\u0435\u043d Joomla! Api token \u0432 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0435 \u043c\u0435\u0441\u0442\u043e, \/\/ \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 \u0438\u043b\u0438 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435. \/\/ \u041c\u044b \u043d\u0435 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \/\/ \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043f\u0430\u0440\u043e\u043b\u0435\u0439. \/\/ \u0417\u0434\u0435\u0441\u044c \u043e\u043f\u0438\u0441\u0430\u043d\u043e \u043f\u043e\u0447\u0435\u043c\u0443: https:\/\/www.trendmicro.com\/en_us\/research\/22\/h\/analyzing-hidden-danger-of-environment-variables-for-keeping-secrets.html $token = ''; <\/code><\/pre>\n<h3>POST &#8212; \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u0432 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 &#171;Uncategorized&#187; (&#171;\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438&#187;) \u043f\u043e REST API \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e cURL<\/h3>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL $curl  = curl_init();  $url   = 'https:\/\/example.org\/api\/index.php\/v1';  $token = '';  $categoryId = 2; \/\/ Joomla's default \"Uncategorized\" Category   $data = [ 'title'       => 'How to add an article to Joomla via the API?', 'alias'       => 'how-to-add-article-via-joomla-api', 'articletext' => 'I have no idea...', 'catid'       => $categoryId, 'language'    => '*', 'metadesc'    => '', 'metakey'     => '', ];  $dataString = json_encode($data);  \/\/ HTTP request headers $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', 'Content-Length: ' . mb_strlen($dataString), sprintf('X-Joomla-Token: %s', trim($token)), ];  curl_setopt_array($curl, [         CURLOPT_URL            => sprintf('%s\/%s',$url,'content\/articles'),         CURLOPT_RETURNTRANSFER => true,         CURLOPT_ENCODING       => 'utf-8',         CURLOPT_MAXREDIRS      => 10,         CURLOPT_TIMEOUT        => 30,         CURLOPT_FOLLOWLOCATION => true,         CURLOPT_HTTP_VERSION   => CURL_HTTP_VERSION_2TLS,         CURLOPT_CUSTOMREQUEST  => 'POST',         CURLOPT_POSTFIELDS     => $dataString,         CURLOPT_HTTPHEADER     => $headers,     ] );  $response = curl_exec($curl); curl_close($curl); echo $response;<\/code><\/pre>\n<h3>GET &#8212; \u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u0432\u0441\u0435\u0445 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 Joomla \u0438\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 &#171;Uncategorized&#187; (&#171;\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438&#187;) \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e cURL \u043f\u043e REST API<\/h3>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL $curl  = curl_init();  $url   = 'https:\/\/example.org\/api\/index.php\/v1';  $token = '';  $categoryId = 2; \/\/ Joomla's default \"Uncategorized\" Category   \/\/ HTTP request headers $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ];  curl_setopt_array($curl, [         CURLOPT_URL            => sprintf('%s\/content\/articles?filter[category]=%d',$url,$categoryId),         CURLOPT_RETURNTRANSFER => true,         CURLOPT_ENCODING       => 'utf-8',         CURLOPT_MAXREDIRS      => 10,         CURLOPT_TIMEOUT        => 30,         CURLOPT_FOLLOWLOCATION => true,         CURLOPT_HTTP_VERSION   => CURL_HTTP_VERSION_2TLS,         CURLOPT_CUSTOMREQUEST  => 'GET',         CURLOPT_HTTPHEADER     => $headers,     ] );  $response = curl_exec($curl); curl_close($curl); echo $response;<\/code><\/pre>\n<h3>GET &#8212; \u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e cURL (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL $curl  = curl_init();  $url   = 'https:\/\/example.org\/api\/index.php\/v1';  $token = '';  $articleId = 1; \/\/ The Article ID of a specific Article   \/\/ HTTP request headers $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ]; curl_setopt_array($curl, [         CURLOPT_URL            => sprintf('%s\/content\/articles\/%d',$url,$articleId),         CURLOPT_RETURNTRANSFER => true,         CURLOPT_ENCODING       => 'utf-8',         CURLOPT_MAXREDIRS      => 10,         CURLOPT_TIMEOUT        => 30,         CURLOPT_FOLLOWLOCATION => true,         CURLOPT_HTTP_VERSION   => CURL_HTTP_VERSION_2TLS,         CURLOPT_CUSTOMREQUEST  => 'GET',         CURLOPT_HTTPHEADER     => $headers,     ] );  $response = curl_exec($curl); curl_close($curl); echo $response;<\/code><\/pre>\n<h2>PATCH &#8212; \u0418\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e cURL (REST API)<\/h2>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL $curl  = curl_init();  $url   = 'https:\/\/example.org\/api\/index.php\/v1';  $token = '';  $articleId = 1; \/\/ The Article ID of a specific Article   $data = [ 'id'          => $articleId, 'title'       => 'How to add an article via the Joomla 4 API?', 'introtext' => 'When using PATCH, articletext MUST be splitted in two parts or use at least just introtext in order to work properly', 'fulltext' => 'MORE CONTENT if you wish', ];  $dataString = json_encode($data);  \/\/ HTTP request headers $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', 'Content-Length: ' . mb_strlen($dataString), sprintf('X-Joomla-Token: %s', trim($token)), ];  curl_setopt_array($curl, [         CURLOPT_URL            => sprintf('%s\/content\/articles\/%d',$url,$articleId),         CURLOPT_RETURNTRANSFER => true,         CURLOPT_ENCODING       => 'utf-8',         CURLOPT_MAXREDIRS      => 10,         CURLOPT_TIMEOUT        => 30,         CURLOPT_FOLLOWLOCATION => true,         CURLOPT_HTTP_VERSION   => CURL_HTTP_VERSION_2TLS,         CURLOPT_CUSTOMREQUEST  => 'PATCH',         CURLOPT_POSTFIELDS     => $dataString,         CURLOPT_HTTPHEADER     => $headers,     ] );  $response = curl_exec($curl); curl_close($curl); echo $response;<\/code><\/pre>\n<h3>DELETE &#8212; \u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e cURL (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL $curl  = curl_init();  $url   = 'https:\/\/example.org\/api\/index.php\/v1';  $token = '';  $articleId = 1; \/\/ The Article ID of a specific Article   \/\/ HTTP request headers $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ];  curl_setopt_array($curl, [         CURLOPT_URL            => sprintf('%s\/content\/articles\/%d',$url,$articleId),         CURLOPT_RETURNTRANSFER => true,         CURLOPT_ENCODING       => 'utf-8',         CURLOPT_MAXREDIRS      => 10,         CURLOPT_TIMEOUT        => 30,         CURLOPT_FOLLOWLOCATION => true,         CURLOPT_HTTP_VERSION   => CURL_HTTP_VERSION_2TLS,         CURLOPT_CUSTOMREQUEST  => 'DELETE',         CURLOPT_HTTPHEADER     => $headers,     ] );  $response = curl_exec($curl); curl_close($curl); echo $response;<\/code><\/pre>\n<h2>\u041f\u043e\u043b\u0435\u0437\u043d\u044b\u0435 \u0440\u0435\u0441\u0443\u0440\u0441\u044b<\/h2>\n<h3>\u0420\u0435\u0441\u0443\u0440\u0441\u044b Joomla \u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0430:<\/h3>\n<ul>\n<li>\n<p><a href=\"https:\/\/joomlaforum.ru\/\" rel=\"noopener noreferrer nofollow\"><u>\u0444\u043e\u0440\u0443\u043c \u0440\u0443\u0441\u0441\u043a\u043e\u0439 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 Joomla<\/u><\/a>.<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/joomlaportal.ru\/\" rel=\"noopener noreferrer nofollow\"><u>\u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442-\u043f\u043e\u0440\u0442\u0430\u043b Joomla-\u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0430<\/u><\/a>.<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/vc.ru\/s\/1146097-joomla\" rel=\"noopener noreferrer nofollow\">https:\/\/vc.ru\/s\/1146097-joomla<\/a>\u00a0&#8212; \u0421\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u043e Joomla \u043d\u0430 VC.<\/p>\n<\/li>\n<\/ul>\n<h3>Joomla \u0432 Telegram:<\/h3>\n<ul>\n<li>\n<p><a href=\"https:\/\/t.me\/joomlaru\" rel=\"noopener noreferrer nofollow\"><u>\u0427\u0430\u0442 \u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0430 \u00abJoomla! \u043f\u043e-\u0440\u0443\u0441\u0441\u043a\u0438\u00bb<\/u><\/a>.<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/t.me\/projoomla\" rel=\"noopener noreferrer nofollow\"><u>Joomla \u0434\u043b\u044f \u043f\u0440\u043e\u0444\u0435\u0441\u0441\u0438\u043e\u043d\u0430\u043b\u043e\u0432, \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 Joomla<\/u><\/a>.<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/t.me\/joomlafeed\" rel=\"noopener noreferrer nofollow\"><u>\u041d\u043e\u0432\u043e\u0441\u0442\u0438 \u043e Joomla! \u0438 \u0432\u0435\u0431-\u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u043f\u043e-\u0440\u0443\u0441\u0441\u043a\u0438<\/u><\/a>.<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/t.me\/joomla_jobs\" rel=\"noopener noreferrer nofollow\"><u>\u0412\u0430\u043a\u0430\u043d\u0441\u0438\u0438 \u0438 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u043f\u043e Joomla<\/u><\/a>: \u0444\u0443\u043b\u043b\u0442\u0430\u0439\u043c, \u0447\u0430\u0441\u0442\u0438\u0447\u043d\u0430\u044f \u0437\u0430\u043d\u044f\u0442\u043e\u0441\u0442\u044c \u0438 \u0440\u0430\u0437\u043e\u0432\u044b\u0435 \u043f\u043e\u0434\u0440\u0430\u0431\u043e\u0442\u043a\u0438. \u0420\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0432\u0430\u043a\u0430\u043d\u0441\u0438\u0439\u00a0<a href=\"https:\/\/jpath.ru\/jobs\/add\" rel=\"noopener noreferrer nofollow\"><u>\u0437\u0434\u0435\u0441\u044c<\/u><\/a>.<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/t.me\/joomlatalks\" rel=\"noopener noreferrer nofollow\">\u0410\u043d\u0433\u043b\u043e\u044f\u0437\u044b\u0447\u043d\u044b\u0439 \u0447\u0430\u0442 \u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0430<\/a>.<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/t.me\/joomlahub\" rel=\"noopener noreferrer nofollow\">\u041d\u043e\u0432\u043e\u0441\u0442\u0438 Joomla! \u043f\u043e-\u0430\u043d\u0433\u043b\u0438\u0439\u0441\u043a\u0438<\/a><\/p>\n<\/li>\n<\/ul>\n<\/div>\n<\/div>\n<\/div>\n<p> <!----> <!----><\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/articles\/747730\/\"> https:\/\/habr.com\/ru\/articles\/747730\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p>\u042d\u0442\u043e\u0442 \u0442\u0435\u043a\u0441\u0442 &#8212;\u00a0<a href=\"https:\/\/manual.joomla.org\/docs\/general-concept\/webservices\" rel=\"noopener noreferrer nofollow\">\u043f\u0435\u0440\u0435\u0432\u043e\u0434\u00a0<\/a>\u0441\u0442\u0430\u0442\u044c\u0438 \u0438\u0437\u00a0<a href=\"https:\/\/manual.joomla.org\/\" rel=\"noopener noreferrer nofollow\">\u043d\u043e\u0432\u043e\u0433\u043e \u043f\u043e\u0440\u0442\u0430\u043b\u0430 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u0434\u043b\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 Joomla<\/a>, \u0440\u0430\u0437\u0434\u0435\u043b &#171;\u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u0438&#187;. \u0420\u0430\u043d\u0435\u0435 \u0443\u0436\u0435 \u0431\u044b\u043b \u043e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043d \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u0440\u0430\u0437\u0434\u0435\u043b\u0430, \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u044e\u0449\u0435\u0433\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u044b <a href=\"https:\/\/habr.com\/ru\/articles\/692342\/\" rel=\"noopener noreferrer nofollow\">Dependency Injection Containers \u0432 Joomla 4<\/a>.<\/p>\n<hr\/>\n<h2>\u041a\u043e\u043d\u0446\u0435\u043f\u0446\u0438\u044f \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432<\/h2>\n<ul>\n<li>\n<p>\u0412\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u0434\u043b\u044f \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c \u0434\u0440\u0443\u0433 \u0441 \u0434\u0440\u0443\u0433\u043e\u043c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0430 HTTP, \u0430 \u0432 \u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0435\u0435 \u0432\u0440\u0435\u043c\u044f \u0438 \u0447\u0435\u0440\u0435\u0437 TLS (\u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u044c \u0442\u0440\u0430\u043d\u0441\u043f\u043e\u0440\u0442\u043d\u043e\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f).<\/p>\n<\/li>\n<li>\n<p>\u0412\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u044b \u0434\u0435\u0439\u0441\u0442\u0432\u0443\u044e\u0442 \u043a\u0430\u043a \u043a\u043e\u043d\u0442\u0440\u0430\u043a\u0442 \u043c\u0435\u0436\u0434\u0443 \u043f\u043e\u0441\u0442\u0430\u0432\u0449\u0438\u043a\u043e\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438 \u043f\u043e\u0442\u0440\u0435\u0431\u0438\u0442\u0435\u043b\u0435\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0447\u0435\u0440\u0435\u0437 Endpoint. <\/p>\n<\/li>\n<li>\n<p>\u0412\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u044b \u043f\u043e\u0434\u043e\u0431\u043d\u044b \u0434\u0432\u0435\u0440\u044f\u043c \u0438 \u043e\u043a\u043d\u0430\u043c \u0432 \u0434\u043e\u043c\u0435, \u043e\u043d\u0438 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u0412\u0425\u041e\u0414\u0410\u041c\u0418 (inputs) \u0438 \u0412\u042b\u0425\u041e\u0414\u0410\u041c\u0418 (outputs) \u0432\u043e \u0412\u041d\u0415\u0428\u041d\u0418\u0419 \u043c\u0438\u0440.<\/p>\n<\/li>\n<li>\n<p>\u0412 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435 Joomla \u043a\u0430\u043a \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0432 \u0446\u0435\u043b\u043e\u043c, Joomla Web services API \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 Joomla \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u0441 \u0432\u043d\u0435\u0448\u043d\u0438\u043c\u0438 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430\u043c\u0438 \u0434\u0430\u043d\u043d\u044b\u0445. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u0435\u0431-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438, \u043c\u043e\u0431\u0438\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438 \u0438 \u0442.\u0434.<\/p>\n<\/li>\n<\/ul>\n<h2>\u0412\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0441 Web Services API Joomla 4.x<\/h2>\n<p>\u0412\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0441 API \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 Joomla 4 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0447\u0435\u0440\u0435\u0437 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u0435 endpoint&#8217;\u044b:<\/p>\n<ul>\n<li>\n<p><a href=\"https:\/\/docs.joomla.org\/J4.x:Joomla_Core_APIs\" rel=\"noopener noreferrer nofollow\">\u0421\u043f\u0438\u0441\u043e\u043a endpoint&#8217;\u043e\u0432 \u044f\u0434\u0440\u0430 Joomla<\/a> (\u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f Joomla)<\/p>\n<\/li>\n<li>\n<p><a href=\"https:\/\/github.com\/alexandreelise\/j4x-api-collection\" rel=\"noopener noreferrer nofollow\">\u041a\u043e\u043b\u043b\u0435\u043a\u0446\u0438\u044f Joomla endpoints \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 Postman<\/a> (GitHub)<\/p>\n<\/li>\n<\/ul>\n<h2>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 Joomla API<\/h2>\n<p>\u0427\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e, \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 Joomla API, \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u043f\u043e-\u043f\u0440\u0435\u0436\u043d\u0435\u043c\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f cURL \u0438\u043b\u0438 php. \u0427\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e cURL \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u043d\u0430 \u0412\u0430\u0448\u0435\u043c \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435. \u0412 \u043f\u0440\u043e\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <code>phpinfo();<\/code> <\/p>\n<h3>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435<\/h3>\n<p>\u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u043c\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u043e \u0432\u0441\u0435\u0445 \u043d\u0430\u0448\u0438\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u0430\u0445:<\/p>\n<ul>\n<li>\n<p>URL \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430 \u043d\u0430 Joomla 4.x<\/p>\n<\/li>\n<li>\n<p>\u0422\u043e\u043a\u0435\u043d Joomla API \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438 \u0441\u0443\u043f\u0435\u0440\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438\u043b\u0438 \u0443\u0447\u0435\u0442\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438, \u0443 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0435\u0441\u0442\u044c, \u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435, \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 <code>core.login.api<\/code> \u0438 <code>core.login.site<\/code>, \u0447\u0442\u043e\u0431\u044b \u0438\u043c\u0435\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u0438\u0434\u0435\u0442\u044c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0442\u043e\u043a\u0435\u043d\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u0432\u043e\u0448\u0435\u0434\u0448\u0435\u0433\u043e \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0443.<\/p>\n<\/li>\n<\/ul>\n<pre><code class=\"php\">&lt;?php \/\/ Before passing the HTTP METHOD to CURL use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  \/\/ \u041f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u0435 \u0412\u0430\u0448 \u0442\u043e\u043a\u0435\u043d Joomla! Api token \u0432 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0435 \u043c\u0435\u0441\u0442\u043e, \/\/ \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 \u0438\u043b\u0438 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435. \/\/ \u041c\u044b \u043d\u0435 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \/\/ \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043f\u0430\u0440\u043e\u043b\u0435\u0439. \/\/ \u0417\u0434\u0435\u0441\u044c \u043e\u043f\u0438\u0441\u0430\u043d\u043e \u043f\u043e\u0447\u0435\u043c\u0443: https:\/\/www.trendmicro.com\/en_us\/research\/22\/h\/analyzing-hidden-danger-of-environment-variables-for-keeping-secrets.html  $token = '';<\/code><\/pre>\n<p>[<a href=\"https:\/\/habr.com\/ru\/articles\/568996\/\" rel=\"noopener noreferrer nofollow\">\u0421\u0442\u0430\u0442\u044c\u044f \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0432\u043d\u0435\u0448\u043d\u0438\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c HttpFactory (Joomla) \u043d\u0430 \u0425\u0430\u0431\u0440\u0435 &#8212; \u0422.\u0421.<\/a>]<\/p>\n<p>\u041f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u0435 \u0412\u0430\u0448 \u0442\u043e\u043a\u0435\u043d Joomla! Api token \u0432 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0435 \u043c\u0435\u0441\u0442\u043e, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u043f\u0430\u0440\u043e\u043b\u0435\u0439 \u0438\u043b\u0438 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435. \u041c\u044b \u043d\u0435 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f  \u043f\u0430\u0440\u043e\u043b\u0435\u0439. \u0417\u0434\u0435\u0441\u044c \u043e\u043f\u0438\u0441\u0430\u043d\u043e \u043f\u043e\u0447\u0435\u043c\u0443 &#8212; \u0441\u0442\u0430\u0442\u044c\u044f &#171;<a href=\"https:\/\/www.trendmicro.com\/en_us\/research\/22\/h\/analyzing-hidden-danger-of-environment-variables-for-keeping-secrets.html\" rel=\"noopener noreferrer nofollow\">Analyzing the Hidden Danger of Environment Variables for Keeping Secrets<\/a>&#187; \u043d\u0430 TrendMicro.com.<\/p>\n<h3>POST &#8212; \u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u0432 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 &#171;Uncategorized&#187; (&#171;\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438&#187;) \u043f\u043e REST API (ID \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 = 2)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = '';  $categoryId = 2; \/\/ \u041a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u044f \"\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438\" Joomla \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e  $data = [ 'title'       => '\u041a\u0430\u043a \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b Joomla \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e REST API?', 'alias'       => '\u043aak-dobavit-material-joomla-s-pomoshhju-rest-api', 'articletext' => '\u042f \u043f\u043e\u043a\u0430 \u043d\u0435 \u0437\u043d\u0430\u044e... \u041f\u043e\u0438\u0449\u0443-\u043a\u0430 \u044f \u043d\u043e\u0432\u0435\u043d\u044c\u043a\u0438\u0435 \u0441\u0442\u0430\u0442\u044c\u0438 \u043e Joomla \u043d\u0430 \u0425\u0430\u0431\u0440\u0435.', 'catid'       => $categoryId, 'language'    => '*', 'metadesc'    => '', 'metakey'     => '', ];  $dataString = json_encode($data);  \/\/ HTTP request headers $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', 'Content-Length: ' . mb_strlen($dataString), sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0435 endpoint \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430\u043c\u0438. \/\/ \u042d\u0442\u043e \u0447\u0430\u0441\u0442\u044c $uri. $uri->setPath('content\/articles');  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('POST', $uri, $dataString, $headers, $timeout);  \/\/ \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043c\u044b \u0438\u043c\u0435\u0435\u043c stream, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0435\u043b\u0430\u0435\u043c \u043f\u0440\u043e\u0441\u0442\u043e: echo $response->body;<\/code><\/pre>\n<h3>\u041d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u043e\u0442\u0441\u0442\u0443\u043f\u043b\u0435\u043d\u0438\u0435 \u043e \u043a\u043b\u0430\u0441\u0441\u0435 Uri \u0432 Joomla (\u043e\u0442 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430)<\/h3>\n<p>\u0414\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0435\u0433\u043e \u043f\u043e\u043d\u0438\u043c\u0430\u043d\u0438\u044f \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u044f\u0449\u0435\u0433\u043e \u0432 \u043a\u043e\u0434\u0435 \u0438 \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0439 \u0431\u043e\u043b\u0435\u0435 \u0443\u0434\u043e\u0431\u043d\u043e\u0439 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 Joomla API \u043f\u043e\u0437\u0432\u043e\u043b\u044e \u0441\u0435\u0431\u0435 \u0432\u043d\u0435\u0434\u0440\u0438\u0442\u044c \u043a\u0440\u0430\u0442\u043a\u0443\u044e \u0441\u043f\u0440\u0430\u0432\u043a\u0443 \u043e \u043a\u043b\u0430\u0441\u0441\u0430\u0445 Uri \u0432 Joomla:<\/p>\n<figure class=\"full-width\"><\/figure>\n<ul>\n<li>\n<p><a href=\"https:\/\/docs.joomla.org\/URLs_in_Joomla\" rel=\"noopener noreferrer nofollow\">\u041e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f Joomla \u043f\u043e \u043a\u043b\u0430\u0441\u0441\u0443 Joomla\\Uri\\Uri<\/a><\/p>\n<\/li>\n<li>\n<p>\u0414\u043e\u043a\u0438 \u0434\u043b\u044f Joomla 3, \u043d\u043e \u043a\u043b\u0430\u0441\u0441 Uri \u0432 Joomla 4 \u043e\u0441\u0442\u0430\u043b\u0441\u044f \u0432 \u0446\u0435\u043b\u043e\u043c \u0442\u0435\u043c \u0436\u0435. <\/p>\n<\/li>\n<li>\n<p>\u0412 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u043f\u043e \u0441\u0441\u044b\u043b\u043a\u0435 \u0443\u043a\u0430\u0437\u0430\u043d \u043a\u043b\u0430\u0441\u0441 <code>Joomla\\CMS\\Uri\\Uri<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u0442 \u043a\u043b\u0430\u0441\u0441 <code>Joomla\\Uri\\Uri<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432 \u0441\u0432\u043e\u044e \u043e\u0447\u0435\u0440\u0435\u0434\u044c, \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u0442 \u043a\u043b\u0430\u0441\u0441 <code>Joomla\\Uri\\AbstractUri<\/code>. \u041c\u0435\u0442\u043e\u0434\u044b \u0440\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u0432 \u0434\u043e\u0447\u0435\u0440\u043d\u0435\u043c.<\/p>\n<\/li>\n<li>\n<p>\u041a\u043b\u0430\u0441\u0441 <code>Joomla\\Uri\\Uri<\/code> \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 url \u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u043d\u0438\u043c \u043a\u0430\u043a \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c: <code>$url->setPath<\/code>, <code>$url->setScheme<\/code>, <code>$url->setScheme<\/code> , <code>$url->setScheme<\/code> \u0438 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043c\u0435\u0442\u043e\u0434\u0430\u043c\u0438 (\u0441\u043f\u0438\u0441\u043e\u043a \u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432 \u0444\u0430\u0439\u043b\u0435 \u043a\u043b\u0430\u0441\u0441\u0430: <em>libraries\/vendor\/joomla\/uri\/src\/Uri.php<\/em>). \u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0433\u0435\u0442\u0442\u0435\u0440\u044b \u0437\u0430\u0434\u0430\u043d\u044b \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 <code>Joomla\\Uri\\AbstractUri<\/code><\/p>\n<\/li>\n<li>\n<p>\u041a\u043b\u0430\u0441\u0441 <code>Joomla\\CMS\\Uri\\Uri<\/code> \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043c\u0435\u0442\u043e\u0434\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0435 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0435\u0439 \u0440\u0430\u0431\u043e\u0442\u044b Joomla: \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0432\u043d\u0435\u0448\u043d\u0438\u0439 \u043b\u0438 \u0438\u043b\u0438 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u0439 url, \u0442\u0435\u043a\u0443\u0449\u0438\u0439 url \u0431\u0435\u0437 GET-\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0438 \u0442.\u0434.<\/p>\n<\/li>\n<\/ul>\n<h3>GET &#8212; \u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u0432\u0441\u0435\u0445 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 Joomla \u0438\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 &#171;Uncategorized&#187; (&#171;\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438&#187;)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = '';  $categoryId = 2; \/\/ \u041a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u044f \"\u0411\u0435\u0437 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438\" Joomla \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e  \/\/ \u041d\u0435 \u0431\u0443\u0434\u0435\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c payload \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 $dataString = null;  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0435 endpoint \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430\u043c\u0438. \/\/ \u042d\u0442\u043e \u0447\u0430\u0441\u0442\u044c $uri. $uri->setPath('content\/articles');  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('GET', $uri, $dataString, $headers, $timeout);  \/\/ \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043c\u044b \u0438\u043c\u0435\u0435\u043c stream, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0435\u043b\u0430\u0435\u043c \u043f\u0440\u043e\u0441\u0442\u043e: echo $response->body;<\/code><\/pre>\n<h3>GET &#8212; \u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = '';  $articleId = 1; \/\/ ID \u043d\u0443\u0436\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u0432 Joomla  \/\/ \u041d\u0435 \u0431\u0443\u0434\u0435\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c payload \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 $dataString = null;  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c path-\u0447\u0430\u0441\u0442\u044c Url \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430. $uri->setPath(sprintf('content\/articles\/%d', $articleId));  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('GET', $uri, $dataString, $headers, $timeout);  \/\/ \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043c\u044b \u0438\u043c\u0435\u0435\u043c stream, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u0435\u043b\u0430\u0435\u043c \u043f\u0440\u043e\u0441\u0442\u043e: echo $response->body;<\/code><\/pre>\n<h3>PATCH &#8212; \u0418\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = ''; $articleId = 1; \/\/ ID \u043d\u0443\u0436\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u0432 Joomla  $data = [ 'id'          => $articleId, 'title'       => '\u041a\u0430\u043a \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b Joomla \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e REST API?', 'introtext' => '\u041f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 PATCH \u0442\u0435\u043a\u0441\u0442 \u0441\u0442\u0430\u0442\u044c\u0438 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0440\u0430\u0437\u0434\u0435\u043b\u0435\u043d \u043d\u0430 \u0434\u0432\u0435 \u0447\u0430\u0441\u0442\u0438 \u0438\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c, \u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435, \u0442\u043e\u043b\u044c\u043a\u043e introtext, \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043e\u043b\u0436\u043d\u044b\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c', 'fulltext' => '\u0411\u043e\u043b\u044c\u0448\u0435 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430 \u0431\u043e\u0433\u0443 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430!', ];  $dataString = json_encode($data);  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type: application\/json', 'Content-Length: ' . mb_strlen($dataString), sprintf('X-Joomla-Token: %s', trim($token)), ];  \/\/ \u0422\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u0441\u0435\u043a\u0443\u043d\u0434\u0430\u0445 $timeout = 30;  \/\/ \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c path-\u0447\u0430\u0441\u0442\u044c Url \u0434\u043b\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430. $uri->setPath(sprintf('content\/articles\/%d', $articleId));  \/\/ \u042d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 PSR-7 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 Response $response = $http->request('PATCH', $uri, $dataString, $headers, $timeout);  \/\/ \u0417\u0434\u0435\u0441\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u043c status code \u0437\u0430\u043f\u0440\u043e\u0441\u0430 echo $response->code;<\/code><\/pre>\n<h4>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430 \u043e \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0435 \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0438 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla<\/h4>\n<p><em>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0447\u0438\u043a\u0430 \u0434\u043b\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432, \u043d\u0435 \u0437\u043d\u0430\u043a\u043e\u043c\u044b\u0445 \u0441\u043e \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u043e\u0439 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 (com_content) Joomla. \u041a\u0430\u0436\u0434\u044b\u0439 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b (article) \u0438\u043c\u0435\u0435\u0442 \u0432\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442 \u0438 \u0432\u0432\u043e\u0434\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442. \u0412\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442\u0441\u044f \u0432 \u0441\u043f\u0438\u0441\u043a\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 \u0432 \u0432\u0438\u0434\u0435 \u0431\u043b\u043e\u0433\u0430 (\u0441 \u043a\u0430\u0440\u0442\u0438\u043d\u043a\u043e\u0439 \u0432\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0442\u0435\u043a\u0441\u0442\u0430, \u043f\u0430\u0440\u043e\u0439 \u0430\u0431\u0437\u0430\u0446\u0435\u0432 \u0438 \u043a\u043d\u043e\u043f\u043a\u043e\u0439 &#171;\u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435&#187;). \u041f\u043e\u043b\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442\u0441\u044f, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043a\u043e\u0433\u0434\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0445\u043e\u0447\u0435\u0442 \u0447\u0438\u0442\u0430\u0442\u044c \u0441\u0442\u0430\u0442\u044c\u044e \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0438 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u0442 \u0435\u0451. <\/em><\/p>\n<p><em>\u0412 \u0431\u0430\u0437\u0435 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 \u0442\u0430\u0431\u043b\u0438\u0446\u0435 \u0434\u043b\u044f \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u043e\u0432 Joomla \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043e 2 \u044f\u0447\u0435\u0439\u043a\u0438: <\/em><strong><em>introtext<\/em><\/strong><em> \u0438 <\/em><strong><em>fulltext<\/em><\/strong><em> \u0442\u0438\u043f\u0430 <\/em><strong><em>MEDIUMTEXT<\/em><\/strong><em> \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e. <\/em><\/p>\n<figure class=\"full-width\"><\/figure>\n<p><em>\u0415\u0441\u043b\u0438 \u043a\u043e\u043d\u0442\u0435\u043d\u0442-\u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0432\u0441\u0442\u0430\u0432\u043a\u0438 \u043b\u0438\u043d\u0438\u0438 &#171;\u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435&#187; \u0432 \u0430\u0434\u043c\u0438\u043d\u043a\u0435 \u0443\u043a\u0430\u0437\u0430\u043b Joomla, \u0447\u0442\u043e \u0442\u0435\u043a\u0441\u0442 \u043d\u0443\u0436\u043d\u043e \u0440\u0430\u0437\u0431\u0438\u0442\u044c \u043d\u0430 \u0432\u0441\u0442\u0443\u043f\u0438\u0442\u0435\u043b\u044c\u043d\u0443\u044e \u0438 \u043f\u043e\u043b\u043d\u0443\u044e \u0447\u0430\u0441\u0442\u044c, \u0442\u043e \u0442\u0435\u043a\u0441\u0442 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0437\u0440\u0435\u0437\u0430\u043d \u043d\u0430 2 \u0447\u0430\u0441\u0442\u0438 \u0438 \u043a\u0430\u0436\u0434\u0430\u044f \u0438\u0437 \u0447\u0430\u0441\u0442\u0435\u0439 \u0431\u0443\u0434\u0435\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u044c\u0441\u044f \u0432 \u0441\u0432\u043e\u0435\u0439 \u044f\u0447\u0435\u0439\u043a\u0435.  \u0415\u0441\u043b\u0438 \u0436\u0435 \u043b\u0438\u043d\u0438\u044f &#171;\u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435&#187; \u043d\u0435 \u0432\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0430, \u0442\u043e \u0432\u0435\u0441\u044c \u0442\u0435\u043a\u0441\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u0441\u044f \u0432 \u044f\u0447\u0435\u0439\u043a\u0435 <\/em><strong><em>introtext<\/em><\/strong><em>.<\/em><\/p>\n<p><em>\u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043f\u0440\u0438 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441 REST API \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0442\u044c \u041a\u0410\u041a \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0440\u0430\u0431\u043e\u0442\u0430 \u0441 \u0442\u0435\u043a\u0441\u0442\u043e\u043c \u043d\u0430 \u0432\u0441\u0435\u0445 \u044d\u0442\u0430\u043f\u0430\u0445: \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435, \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0443, \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0441\u0430\u0439\u0442\u0430. \u0415\u0441\u043b\u0438 Joomla \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0431\u044d\u043a\u0435\u043d\u0434, \u0430 \u0444\u0440\u043e\u043d\u0442 &#8212; \u044d\u0442\u043e \u043c\u043e\u0431\u0438\u043b\u044c\u043d\u043e\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0438\u043b\u0438 \u0444\u0440\u043e\u043d\u0442 \u0441\u0434\u0435\u043b\u0430\u043d \u043d\u0430 js-\u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0435, \u0442\u043e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u0443\u0436\u0435 \u043d\u0435 \u043e\u0442 Joomla, \u0430 \u043e\u0442 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0438 \u0442\u043e\u0433\u0434\u0430 \u0432\u0435\u0441\u044c \u0442\u0435\u043a\u0441\u0442 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 \u043c\u043e\u0436\u043d\u043e \u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0432 introtext. \u0415\u0441\u043b\u0438 \u0436\u0435 REST API \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438, \u0430 \u0434\u043b\u044f \u043f\u043e\u0441\u0435\u0442\u0438\u0442\u0435\u043b\u0435\u0439 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f HTML-\u0432\u044b\u0432\u043e\u0434 Joomla, \u0442\u043e \u0441\u043e\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u0435 \u043f\u0440\u0430\u0432\u0438\u043b \u0438\u0433\u0440\u044b CMS \u0431\u0443\u0434\u0435\u0442 \u0432\u0430\u0436\u043d\u044b\u043c, \u0442\u0430\u043a \u043a\u0430\u043a \u044d\u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u0432\u043b\u0438\u044f\u0442\u044c \u043d\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0434\u043b\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u0441\u0430\u0439\u0442\u0430.<\/em> <\/p>\n<h3>DELETE &#8212; \u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0430 Joomla \u043f\u043e id (REST API)<\/h3>\n<pre><code class=\"php\">&lt;?php use Joomla\\Http\\HttpFactory; use Joomla\\Uri\\Uri;  $http = (new HttpFactory())->getAvailableDriver(); $url   = 'https:\/\/example.org\/api\/index.php\/v1'; $uri  = new Uri($url);  $token = ''; $articleId = 1; \/\/ ID \u043d\u0443\u0436\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u0432 Joomla  \/\/ \u041d\u0435 \u0431\u0443\u0434\u0435\u043c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c payload \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 $dataString = null;  \/\/ HTTP \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 $headers = [ 'Accept: application\/vnd.api+json', 'Content-Type:<\/code><\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-350687","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/350687","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=350687"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/350687\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=350687"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=350687"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=350687"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}