Skip to main content

Hello,

I have a problem When I build my envelope with additionalNotification,I want a SMS notification but the Docusign API say that my vountry_code is not present. But I made that (in PHP) :

 

                        $additionnalNotification = new \DocuSign\eSign\Model\RecipientAdditionalNotification(N

                            "secondary_delivery_method" => "SMS",

                            "phone_number" =>

                                "country_code" =>”33”,

                                "number" => “625589878”

                            ]

                            ]);

 

The country code is the country code of france.

 

I get: 

Error while requesting server, received a non successful HTTP code o400] with response Body: O:8:"stdClass":2:{s:9:"errorCode";s:34:"INVALID_PHONE_NUMBER_FOR_RECIPIENT";s:7:"message";s:73:"The Phone number is invalid. Country code is missing. Recipient id: 10511"

as I test by REST API:

"additionalNotifications": [

{

"secondaryDeliveryMethod": "sms",

"phoneNumber": {

"countryCode": "86",

"number": "13912341234"

}

}

]

 

it is working. could you share the API log of the request json?

 

FreeLink/甫连信息

🌍 DocuSign Partner | Partner Profile

🏆 DocuSign 2024 APAC Reseller Growth Partner of the Year

🌟 The only DocuSign Partner globally certified as both a Certified eSignature Administrator and eSignature Technical Consultant.

📊 DocuSign Community Leaderboard Top 5 contributor.

🚀 Expertise in DocuSign integrations with on-premises systems for leading enterprises across various industries.


Thanks ​@Hengfeng Ge, it’s ok for me. 

The php SDK not changing country_code to countryCode in JSON.


Hello Thomas,

 

As Hengfeng mentioned the issue is possibly caused due to possibly a syntax issue, and the sample code is valid. Here is a sample from PHP.


$additionalNotification = new \DocuSign\eSign\Model\RecipientAdditionalNotification((
    "secondary_delivery_method" => "SMS",
    "phone_number" => &
        "country_code" => "33", // Ensure this is a string
        "number" => "625589878" // Ensure this contains only numeric characters
    ]
]);

Thanks,


Reply