JSON is a format for structuring data that is sent back and forth via an API. JSON is an alternative to XML. Representational State Transfer (REST) APIs more commonly respond with JSON, which is an open standard format that uses human-readable text to transmit data objects consisting of attribute–value pairs. It is easy for humans to read and write. It is easy for machines to parse and generate.