Update APIMethods.md

Added sample code for ruby and python to call the API