Skip to content

Documentation for people v1 API create_contact has unused kwarg parent #775

@edilson-silva

Description

@edilson-silva

I am trying to create a contact, but I am getting the following error message.

Exception Class: TypeError
Exception Message: Got an unexpected keyword argument "parent"

Lib version: 1.2

import httplib2
from apiclient.discovery import build
from oauth2client.file import Storage

storage = Storage('session.dat')
credentials = storage.get()

http = httplib2.Http()
credentials.authorize(http)

created_contacts = list()

new_contact = {
    'names': [
        {
            'displayName': 'Test Contact',
            'givenName': 'Test Contact',
            'displayNameLastFirst': 'Test Contact'
        }
    ],
    'phoneNumbers': [
        {
            'value': '+55 11 99999-9999',
            'canonicalForm': '+55 11 99999-9999'
        }
    ]
}

contact_info = build(serviceName='people', version='v1', http=http) \
    .people() \
    .createContact(parent='people/me', body=new_contact) \
    .execute()

Metadata

Metadata

Assignees

Labels

🚨This issue needs some love.priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.type: docsImprovement to the documentation for an API.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions