Jetpack_JSON_API_Translations_Endpoint

The WordPress Core Jetpack JSON API Translations Endpoint class.

Defined (1)

The class is defined in the following location(s).

/json-endpoints/jetpack/class.jetpack-json-api-translations-endpoint.php  
  1. class Jetpack_JSON_API_Translations_Endpoint extends Jetpack_JSON_API_Endpoint { 
  2. // GET /sites/%s/translations 
  3. // POST /sites/%s/translations 
  4. // POST /sites/%s/translations/update 
  5. protected $needed_capabilities = array( 'update_core', 'update_plugins', 'update_themes' ); 
  6. protected $log; 
  7. protected $success; 
  8.  
  9. public function result() { 
  10. return array( 
  11. 'translations' => wp_get_translation_updates(),  
  12. 'autoupdate' => Jetpack_Options::get_option( 'autoupdate_translations', false ),  
  13. 'log' => $this->log,  
  14. 'success' => $this->success,  
  15. );