How to attach URLs to a row using the Node.js SDK?
System
Employee
This discussion was created from comments split from: Attach File or URL to Row - Request Body for cURL or Python.
Answers
-
Has anyone figured out how to attach URLs to a row using the Node.js SDK? More specifically, does anyone know the addRowUrlAttachment method request body? I understand a sheetId and rowId are needed, but there's no documentation that shows the rest of the syntax. The Smartsheet API docs only show an example using the addRowFileAttachment method, which is not what I'm looking for.
-
Hi @Josh Rosenfeld Have done to attach URL to a row in python script and not in nodejs. Might be syntax will be differ and kindly refer the below code.
you have create an attachment object model by using attachment type as "LINK"
attachment_url - it should be your URL
# Create an Attachment object
attachment = smartsheet.models.Attachment({
'attachmentType': "LINK",
'url': attachment_url
})
# Attach the URL to the row
attachment_result = ss_client.Attachments.attach_url_to_row(sheet_id,row.id,attachment)
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 64.1K Get Help
- 414 Global Discussions
- 221 Industry Talk
- 461 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 141 Just for fun
- 58 Community Job Board
- 462 Show & Tell
- 32 Member Spotlight
- 1 SmartStories
- 299 Events
- 38 Webinars
- 7.3K Forum Archives