Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
neilreyes opened this issue Apr 30, 2023 · 0 comments

Comments

@neilreyes
Copy link

neilreyes commented Apr 30, 2023

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);
                    }
                }
            );
        });
        ``
        ```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant