File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change 1+ # -*- coding: utf-8 -*-
2+ #
3+ # Copyright ©2018-2019 Google LLC
4+ #
5+ # Licensed under the Apache License, Version 2.0 (the "License");
6+ # you may not use this file except in compliance with the License.
7+ # You may obtain a copy of the License at apache.org/licenses/LICENSE-2.0.
8+ #
9+ # Unless required by applicable law or agreed to in writing, software
10+ # distributed under the License is distributed on an "AS IS" BASIS,
11+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+ # See the License for the specific language governing permissions and
13+ # limitations under the License.
14+
15+ """
16+ ouput-json.py (Python 2.x or 3.x)
17+ Google Docs (REST) API output-json sample app
18+ """
19+ # [START output_json_python]
120from __future__ import print_function
221from apiclient import discovery
322from httplib2 import Http
2544# Do a document "get" request and print the results as formatted JSON
2645result = service .documents ().get (documentId = DOCUMENT_ID ).execute ()
2746print (json .dumps (result , indent = 4 , sort_keys = True ))
47+ # [END output_json_python]
You can’t perform that action at this time.
0 commit comments