/** * This snippet has been automatically generated and should be regarded as a code template only. * It will require modifications to work. * It may require correct/in-range values for request initialization. * TODO(developer): Uncomment these variables before running the sample. *//** * Required. Parent project that will own the dataset. * Format: projects/{project} */// const parent = 'abc123'/** * Required. The dataset version to create. */// const dataset = {}// Imports the Mapsplatformdatasets libraryconst{MapsPlatformDatasetsClient}=require('@googlemaps/maps-platform-datasets').v1;// Instantiates a clientconstmapsplatformdatasetsClient=newMapsPlatformDatasetsClient();asyncfunctioncallCreateDataset(){// Construct requestconstrequest={parent,dataset,};// Run requestconstresponse=awaitmapsplatformdatasetsClient.createDataset(request);console.log(response);}callCreateDataset();
# This snippet has been automatically generated and should be regarded as a# code template only.# It will require modifications to work:# - It may require correct/in-range values for request initialization.# - It may require specifying regional endpoints when creating the service# client as shown in:# https://googleapis.dev/python/google-api-core/latest/client_options.htmlfromgoogle.mapsimportmapsplatformdatasets_v1defsample_create_dataset():# Create a clientclient=mapsplatformdatasets_v1.MapsPlatformDatasetsClient()# Initialize request argument(s)request=mapsplatformdatasets_v1.CreateDatasetRequest(parent="parent_value",)# Make the requestresponse=client.create_dataset(request=request)# Handle the responseprint(response)
[[["Прост для понимания","easyToUnderstand","thumb-up"],["Помог мне решить мою проблему","solvedMyProblem","thumb-up"],["Другое","otherUp","thumb-up"]],[["Отсутствует нужная мне информация","missingTheInformationINeed","thumb-down"],["Слишком сложен/слишком много шагов","tooComplicatedTooManySteps","thumb-down"],["Устарел","outOfDate","thumb-down"],["Проблема с переводом текста","translationIssue","thumb-down"],["Проблемы образцов/кода","samplesCodeIssue","thumb-down"],["Другое","otherDown","thumb-down"]],["Последнее обновление: 2025-08-15 UTC."],[[["\u003cp\u003eThis page provides instructions on getting started with the Maps Datasets API client libraries for Node.js and Python.\u003c/p\u003e\n"],["\u003cp\u003eYou'll learn how to install the necessary client libraries using npm or pip.\u003c/p\u003e\n"],["\u003cp\u003eAuthentication is handled using Application Default Credentials (ADC), and the page links to resources for setting up ADC.\u003c/p\u003e\n"],["\u003cp\u003eCode samples demonstrate basic usage of the client libraries, such as creating a dataset, for both Node.js and Python.\u003c/p\u003e\n"],["\u003cp\u003eLinks to additional resources like source code, issue trackers, and Stack Overflow are provided for further assistance.\u003c/p\u003e\n"]]],["To utilize the Maps Datasets API client libraries, first, install the library using `npm install @googlemaps/maps-platform-datasets` for Node.js or `pip install --upgrade google-maps-mapsplatformdatasets` for Python. Set up Application Default Credentials (ADC) for authentication. Node.js and Python code examples show creating a dataset by instantiating a client, constructing a request, and making the request. Additional resources include links to source code, issue trackers, and Stack Overflow.\n"],null,["This page shows how to get started with the client libraries for\nMaps Datasets API.\n\nRead more about the client libraries in [Client Libraries\nExplained](https://cloud.google.com/apis/docs/client-libraries-explained).\n\nInstall the client library \n\nNode.js\n\nFor more information, see [Setting Up a Node.js Development Environment](https://cloud.google.com/nodejs/docs/setup). \n\n```\nnpm install @googlemaps/maps-platform-datasets\n```\n\nPython\n\nFor more information, see [Setting Up a Python Development Environment](https://cloud.google.com/python/docs/setup). \n\n```\npip install --upgrade google-maps-mapsplatformdatasets\n```\n\nSet up authentication\n\nWhen you use client libraries, you use\n[Application Default Credentials (ADC)](https://cloud.google.com/docs/authentication/application-default-credentials)\nto authenticate. For information about setting up ADC, see\n[Provide credentials for Application Default Credentials](https://cloud.google.com/docs/authentication/provide-credentials-adc).\nFor information about using ADC with client libraries, see\n[Authenticate using client libraries](https://cloud.google.com/docs/authentication/client-libraries).\n\nUse the client library \n\nNode.js \n[View on GitHub](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.create_dataset.js) \n\n /**\n * This snippet has been automatically generated and should be regarded as a code template only.\n * It will require modifications to work.\n * It may require correct/in-range values for request initialization.\n * TODO(developer): Uncomment these variables before running the sample.\n */\n /**\n * Required. Parent project that will own the dataset.\n * Format: projects/{project}\n */\n // const parent = 'abc123'\n /**\n * Required. The dataset version to create.\n */\n // const dataset = {}\n\n // Imports the Mapsplatformdatasets library\n const {MapsPlatformDatasetsClient} = require('@googlemaps/maps-platform-datasets').v1;\n\n // Instantiates a client\n const mapsplatformdatasetsClient = new MapsPlatformDatasetsClient();\n\n async function callCreateDataset() {\n // Construct request\n const request = {\n parent,\n dataset,\n };\n\n // Run request\n const response = await mapsplatformdatasetsClient.createDataset(request);\n console.log(response);\n }\n\n callCreateDataset();\n\nPython \n[View on GitHub](https://github.com/googleapis/google-cloud-python/blob/main/packages/google-maps-mapsplatformdatasets/samples/generated_samples/mapsplatformdatasets_v1_generated_maps_platform_datasets_create_dataset_sync.py) \n\n # This snippet has been automatically generated and should be regarded as a\n # code template only.\n # It will require modifications to work:\n # - It may require correct/in-range values for request initialization.\n # - It may require specifying regional endpoints when creating the service\n # client as shown in:\n # https://googleapis.dev/python/google-api-core/latest/client_options.html\n from google.maps import mapsplatformdatasets_v1\n\n\n def sample_create_dataset():\n # Create a client\n client = mapsplatformdatasets_v1.MapsPlatformDatasetsClient()\n\n # Initialize request argument(s)\n request = mapsplatformdatasets_v1.CreateDatasetRequest(\n parent=\"parent_value\",\n )\n\n # Make the request\n response = client.create_dataset(request=request)\n\n # Handle the response\n print(response)\n\nAdditional resources \n\nNode.js\n\n- [Source Code](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-maps-mapsplatformdatasets)\n- [GitHub Issue Tracker](https://github.com/googleapis/google-cloud-node/issues)\n- [Stack Overflow](https://stackoverflow.com/questions/tagged/google-geocoding-api+node.js)\n\nPython\n\n- [Source Code](https://github.com/googleapis/google-cloud-python/tree/main/packages/google-maps-mapsplatformdatasets)\n- [GitHub Issue Tracker](https://github.com/googleapis/google-cloud-python/issues)\n- [Stack Overflow](https://stackoverflow.com/questions/tagged/google-geocoding-api+python)"]]