Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions _includes/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<h1><a href="{{ site.baseurl }}">WP REST API</a></h1>
<nav>
<ul>
<li><a href="https://github.com/WP-API/docs-ja">Documentation on GitHub</a></li>
<li><a href="https://github.com/WP-API/WP-API">Source on GitHub</a></li>
<li><a href="https://github.com/WP-API/WP-API/issues">Support</a></li>
<li><a class="button download" href="https://wordpress.org/plugins/rest-api/">Download</a></li>
<li><a href="https://github.com/WP-API/docs-ja">GitHubドキュメント</a></li>
<li><a href="https://github.com/WP-API/WP-API">GitHubソース</a></li>
<li><a href="https://github.com/WP-API/WP-API/issues">サポート</a></li>
<li><a class="button download" href="https://wordpress.org/plugins/rest-api/">ダウンロード</a></li>
</ul>
</nav>
</header>
10 changes: 5 additions & 5 deletions _includes/reference-parts/args-list.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{% if include.args.size > 0 %}
<h3>Arguments</h3>
<h3>引数</h3>
<table class="arguments">
{% for arg in include.args %}
<tr>
Expand All @@ -16,21 +16,21 @@ <h3>Arguments</h3>
{% endif %}
{% if arg[1].required %}
<p class="required">
Required: {{ arg[1].required }}
必須: {{ arg[1].required }}
</p>
{% endif %}
{% if arg[1].default %}
<p class="default">
Default: <code>{{ arg[1].default }}</code>
初期値: <code>{{ arg[1].default }}</code>
</p>
{% endif %}
{% if arg[1].enum %}
<p>One of: <code>{{ arg[1].enum | join:"</code>, <code>"}}</code></p>
<p>次のいずれか: <code>{{ arg[1].enum | join:"</code>, <code>"}}</code></p>
{% endif %}
</td>
</tr>
{% endfor %}
</table>
{% else %}
<p>There are no arguments for this enpdoint.
<p>このエンドポイントには引数がありません。
{% endif %}
4 changes: 2 additions & 2 deletions _includes/reference-parts/create-item.html
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<section class="route">
<div class="primary">
<h2>Create a {{ page.resource }}</h2>
<h2>{{ page.resource }}を作成</h2>
{% assign args = include.route.endpoints[1].args %}
{% include reference-parts/args-list.html args=args link=true %}
</div>
<div class="secondary">
<h3>Definition</h3>
<h3>定義</h3>

<code>POST {{ include.route.nicename }}</code>
</div>
Expand Down
6 changes: 3 additions & 3 deletions _includes/reference-parts/delete-item.html
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@

<section class="route">
<div class="primary">
<h2>Delete a {{ page.resource }}</h2>
<h2>{{ page.resource }}を削除</h2>
{% assign args = include.route.endpoints[2].args %}
{% include reference-parts/args-list.html args=args %}
</div>
<div class="secondary">
<h3>Definition</h3>
<h3>定義</h3>

<code>DELETE {{ include.route.nicename }}</code>

<h3>Example Request</h3>
<h3>リクエスト例</h3>

<code>$ curl -X DELETE http://demo.wp-api.org/wp-json{{ include.route.nicename }}</code>
</div>
Expand Down
6 changes: 3 additions & 3 deletions _includes/reference-parts/get-item.html
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<section class="route">
<div class="primary">
<h2>Retrieve a {{ page.resource }}</h2>
<h2>{{ page.resource }}を取得する</h2>
{% assign args = include.route.endpoints[0].args %}
{% include reference-parts/args-list.html args=args link=false %}
</div>
<div class="secondary">
<h3>Definition</h3>
<h3>定義</h3>

<code>GET {{ include.route.nicename }}</code>

<h3>Example Request</h3>
<h3>リクエスト例</h3>

<code>$ curl http://demo.wp-api.org/wp-json{{ include.route.nicename }}</code>
</div>
Expand Down
6 changes: 3 additions & 3 deletions _includes/reference-parts/list-item.html
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<section class="route">
<div class="primary">
<h2>List {{ page.resource }}s</h2>
<h2>{{ page.resource }}一覧</h2>
{% assign args = include.route.endpoints[0].args %}
{% include reference-parts/args-list.html args=args link=false %}
</div>
<div class="secondary">
<h3>Definition</h3>
<h3>定義</h3>

<code>GET {{ include.route.nicename }}</code>

<h3>Example Request</h3>
<h3>リクエスト例</h3>

<code>$ curl http://demo.wp-api.org/wp-json{{ include.route.nicename }}</code>
</div>
Expand Down
10 changes: 5 additions & 5 deletions _includes/reference-parts/schema.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<h2>Schema</h2>
<p>The schema defines all the fields that exist for a {{ include.schema.title }} object.</p>
<h2>スキーマ</h2>
<p>スキーマは{{ include.schema.title }}オブジェクトに存在するすべてのフィールドを定義しています。</p>
<table class="attributes">
{% for property in include.schema.properties %}
<tr id="schema-{{ property[0] }}">
Expand All @@ -19,11 +19,11 @@ <h2>Schema</h2>
<td>
<p>{{ property[1].description }}</p>
{% if property[1].readonly %}
<p class="read-only">Read only</p>
<p class="read-only">読み取り専用</p>
{% endif %}
<p class="context">Context: <code>{{ property[1].context | join:"</code>, <code>"}}</code></p>
<p class="context">コンテキスト: <code>{{ property[1].context | join:"</code>, <code>"}}</code></p>
{% if property[1].enum %}
<p>One of: <code>{{ property[1].enum | join:"</code>, <code>"}}</code></p>
<p>次のいずれか: <code>{{ property[1].enum | join:"</code>, <code>"}}</code></p>
{% endif %}
</td>
</tr>
Expand Down
6 changes: 3 additions & 3 deletions _includes/reference-parts/update-item.html
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<section class="route">
<div class="primary">
<h2>Update a {{ page.resource }}</h2>
<h2>{{ page.resource }}を更新する</h2>
{% assign args = include.route.endpoints[1].args %}
{% include reference-parts/args-list.html args=args link=true %}
</div>
<div class="secondary">
<h3>Definition</h3>
<h3>定義</h3>

<code>POST {{ include.route.nicename }}</code>

<h3>Example Request</h3>
<h3>リクエスト例</h3>
{% capture example_include %}reference-parts/examples/update-{{ include.route.schema.title }}-curl.html{% endcapture %}

<code>{% include {{ example_include }} %}</code>
Expand Down
46 changes: 23 additions & 23 deletions _includes/resources.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
---
title: WP REST API v2 Resources
title: WP REST API v2 リソース
---
Resources
リソース
=========

Client Libraries
クライアント・ライブラリ
----------------

* [Backbone.js client][]
Expand All @@ -21,17 +21,17 @@ Client Libraries
[C# client]: https://github.com/maxcutler/wp-api-csharp
[Mixradio API client for Windows Phone]: https://github.com/mixradio/wp-api-client

Authentication
認証
--------------

* [OAuth 1.0a server plugin][]
* [Basic Authentication][]
* [OAuth 1.0aサーバープラグイン][]
* [ベーシック認証][]

[OAuth 1.0a server plugin]: https://github.com/WP-API/OAuth1
[Basic Authentication]: https://github.com/WP-API/Basic-Auth
[OAuth 1.0aサーバープラグイン]: https://github.com/WP-API/OAuth1
[ベーシック認証]: https://github.com/WP-API/Basic-Auth


Tools
ツール
-----

* [WP-CLI client][]
Expand All @@ -45,7 +45,7 @@ Tools
[API client UI]: https://github.com/modemlooper/Api-Clients


WordPress Plugin Integrations
WordPress Plugin インテグレーション
------------------------------
* [BuddyPress][]
* [bbPress][]
Expand All @@ -61,7 +61,7 @@ WordPress Plugin Integrations



Slides & Videos
スライド&ビデオ
---------------

* [Rachel Baker: Put Your Content to REST With WP-API][]
Expand All @@ -78,7 +78,7 @@ Slides & Videos
[K. Adam White: WordPress in Weird Places]: http://kadamwhite.github.io/talks/2014/wcsf-node-wp/#/
[Ryan McCue: The WordPress REST API (WCNYC)]: https://wordpress.tv/2014/11/19/ryan-mccue-the-wordpress-rest-api/

REST Info & Tools
RESTについての情報とツール
-----------------

* [More About REST][]
Expand All @@ -91,19 +91,19 @@ REST Info & Tools
[Paw HTTP App for OSX]: http://luckymarmot.com/paw
[JSONView Chrome Extension]: https://chrome.google.com/webstore/detail/jsonview/chklaanhfefbnpoihckbnefhakgolnmc

Tutorials
チュートリアル
---------
* [An Overview of the WordPress JSON API][] Detailed Overview of the REST API projects and helpful links.
* [Using the WordPress REST API in a mobile app][] A detailed tutorial with complete example code on the basics of using the REST API in a app outside of WordPress.
* [An Overview of the WordPress JSON API][] REST APIについての詳細な概要とお役立ちリンク集。(英語)
* [Using the WordPress REST API in a mobile app][] WordPressの外部からREST APIを利用するための完全なコード例がついた詳しいチュートリアル。(英語)
* [WordPress REST API][] A basic introduction to the REST API.
* [A Look at the WordPress HTTP API][] Part of a series on the WordPress HTTP API, which can be used to interact with the WordPress REST API from within WordPress.
* [Designing a class: WordPress API client][] Guide to building a class for making GET requests to the REST API's users end point via the WordPress HTTP API.
* [An Introduction To The JSON REST API][] An introduction to interacting with the REST API from inside of WordPress, showing how to retrieve and display data from the current site or a remote site via GET requests.
* [An Introduction To The JSON REST API Part2][] More information on how interact with the REST API from inside of WordPress, showing how to create posts using data from a remote site, or create posts on a remote site.
* [Using AngularJS And JSON API In Your WordPress Theme][] An introduction to using the REST API, and Angular JS in a WordPress theme.
* [Working with Meta Data Using the JSON REST API][] Using the REST API to work with post meta data.
* [Working with Taxonomies Using the JSON REST API][] Using the REST API to work with taxonomies.
* [Processing Forms with AJAX Using the JSON REST API][] A guide to using the REST API to edit posts using AJAX.
* [A Look at the WordPress HTTP API][] WordPress HTTP APIに関する連載の一部。WordPress内部でWordPressのREST APIを利用するのに役立つ。(英語)
* [Designing a class: WordPress API client][] WordPrssのHTTP APIを利用してユーザーのエンドポイントにGETリクエストを投げるクラスを作るためのガイド。(英語)
* [An Introduction To The JSON REST API][] WordPressの内部からREST APIを利用するためのレッスンで、GETリクエストで外部または内部のサイトからデータを取得して表示するにはどうすればよいかがわかる。(英語)
* [An Introduction To The JSON REST API Part2][] WordPressの内部からREST APIを利用するにはどうしたらいいかについての詳しい情報。外部のサイトのデータから投稿を作成する方法、外部のサイトにデータを作成する方法がわかる。(英語)
* [Using AngularJS And JSON API In Your WordPress Theme][] WordPressテーマでAngular JSを利用してREST APIを利用する方法。(英語)
* [Working with Meta Data Using the JSON REST API][] REST APIを使って投稿のメタデータを操作する。(英語)
* [Working with Taxonomies Using the JSON REST API][] REST APIを使ってタクソノミーを操作する。(英語)
* [Processing Forms with AJAX Using the JSON REST API][] AJAXで投稿を編集するためのガイド。(英語)

[An Overview of the WordPress JSON API]:http://webdevstudios.com/2014/10/16/an-overview-of-wordpress-json-api/
[Using the WordPress REST API in a mobile app]: http://apppresser.com/using-wordpress-rest-api-mobile-app/
Expand Down
8 changes: 4 additions & 4 deletions reference/index.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
---
page: introduction
title: API Reference
title: APIリファレンス
has_superbar: Yes
---

{% capture intro %}
# API Reference
# APIリファレンス

The API is organized around [REST][]. Our API is designed to have predictable, resource-oriented URLs and to use HTTP response codes to indicate API errors. We use built-in HTTP features, like HTTP authentication and HTTP verbs, which can be understood by off-the-shelf HTTP clients, and we support cross-origin resource sharing to allow you to interact securely with our API from a client-side web application. JSON will be returned in all responses from the API, including errors.
APIは[REST][]にのっとって整備されています。私達のAPIは、予測しやすく、リソース志向のURLを持ち、APIエラーを示すためにHTTPレスポンスコードを利用します。また、ありきたりなHTTPクライアントでも理解できる、HTTP認証やHTTPメソッドのようなHTTPの組み込み機能を利用しています。そして、クロス・オリジンなリソース共有もサポートしており、あなたは私達が提供するAPIでクライアントサイドWebアプリケーションから安全にAPIを利用できます。すべてのAPIレスポンスはJSONで返却され、エラーもそこに含まれます。

[REST]: http://en.wikipedia.org/wiki/Representational_state_transfer
[REST]: https://ja.wikipedia.org/wiki/REST
{% endcapture %}

<section class="route">
Expand Down