Skip to content

"error": "Error 500: TypeError: Cannot read properties of undefined (reading 'unique_id')" #101

Description

@neilreyes

I'm testing this tutorial 'Creates a link for the embedded invite.' and one of the example.

It returns this error:
"error": "Error 500: TypeError: Cannot read properties of undefined (reading 'unique_id')"

My code is below:

``const email_address = 'mygmail.com';
const templateDocId= 'docIdStringhere'  //SignNow templateId;
const fieldInvite = {
            unique_id: templateDocId,
            from: "mygmail.com",
            to: [
                {
                    email: email_address,
                    role: "Signer 1",
                    order: 1,
                    reassign: "0",
                    decline_by_signature: "0",
                    reminder: 4,
                    expiration_days: 27,
                    subject: "Field invite Signer1",
                    message: "Message",
                },
            ],
        };
const sign_invite = await new Promise((resolve, reject) => {
            signNowAPI.template.invite(
                {
                    data: {
                        ...fieldInvite,
                    },
                    id: templateDocId,
                    token: signNowToken,
                },
                (error, response) => {
                    if (error) {
                        reject(error);
                    } else {
                        resolve(response);
                    }
                }
            );
        });
        ``
        ```

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions