Check your version

This video covers a topic in Drupal 7 which may or may not be the version you're using. We're keeping this tutorial online as a courtesy to users of Drupal 7, but we consider it archived.

Alternate resources: 

Altering the Response Object

Video loading...

Join Drupalize.Me to watch this video

Join today and gain instant access to our entire video library.

Log in Sign up
  • 0:05
    with Joe Shindelar
  • 0:07
    Like most modules in Drupal,
  • 0:09
    the Services module comes with the whole suite of different hooks we
  • 0:12
    can implement in order to alter the way that it works.
  • 0:17
    In this lesson, I would like to take a look at how we can alter
  • 0:20
    the responses that we're getting from the Services module.
  • 0:23
    Thus far, when we've requested a node,
  • 0:26
    we've gotten the complete node object as JSON data.
  • 0:29
    But that might not always be the best fit for the application
  • 0:32
    that we're building.

Altering the Response Object

Loading...

Services implements resources for all of core's basic data types but sometimes the information returned in the response is either to much or to little and we want to make changes to the response data. In this lesson Joe will look at how we can write a simple custom module that implments basic hooks provided by the services module to allow us to alter the response returned by a request to the node resource.

Downloads: 
Log in or sign up to download companion files.

Additional resources:
There are no resources for this video. If you believe there should be, please contact us.