add_signature_tag
Place signature or form tags on digital documents using placeholder text or precise coordinates for accurate positioning within signature envelopes.
Instructions
Place a signature or form tag on a document. Use placeholder for text-based positioning or coordinates for exact placement.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| envelopeId | Yes | Envelope UUID | |
| recipientId | Yes | Recipient UUID | |
| documentId | No | Document UUID (required for coordinate positioning) | |
| type | No | Tag type (default: signature) | |
| placeholder | No | Placeholder text to find in document (e.g. "{podpis_klient}") | |
| positioning | No | How tag aligns to placeholder | |
| scale | No | Tag size as percentage (default 100). Use 50-80 for smaller tags. | |
| page | No | Page number (for coordinate positioning) | |
| xPosition | No | X position in points (for coordinate positioning) | |
| yPosition | No | Y position in points (for coordinate positioning) |
Implementation Reference
- src/index.js:237-244 (handler)The handler function for the 'add_signature_tag' tool, which calls `api.addTag`.
async ({ envelopeId, ...tagParams }) => { try { const data = await api.addTag(creds, envelopeId, tagParams); return result(data); } catch (err) { return errorResult(err); } } - src/index.js:225-236 (schema)The input schema validation for the 'add_signature_tag' tool.
{ envelopeId: z.string().describe('Envelope UUID'), recipientId: z.string().describe('Recipient UUID'), documentId: z.string().optional().describe('Document UUID (required for coordinate positioning)'), type: z.enum(['signature', 'approval', 'text', 'date_of_signature', 'checkbox']).optional().describe('Tag type (default: signature)'), placeholder: z.string().optional().describe('Placeholder text to find in document (e.g. "{podpis_klient}")'), positioning: z.enum(['top_left', 'top_center', 'top_right', 'middle_left', 'center', 'middle_right', 'bottom_left', 'bottom_center', 'bottom_right']).optional().describe('How tag aligns to placeholder'), scale: z.number().optional().describe('Tag size as percentage (default 100). Use 50-80 for smaller tags.'), page: z.number().optional().describe('Page number (for coordinate positioning)'), xPosition: z.number().optional().describe('X position in points (for coordinate positioning)'), yPosition: z.number().optional().describe('Y position in points (for coordinate positioning)'), }, - src/index.js:222-245 (registration)The registration of the 'add_signature_tag' tool using `server.tool`.
server.tool( 'add_signature_tag', 'Place a signature or form tag on a document. Use placeholder for text-based positioning or coordinates for exact placement.', { envelopeId: z.string().describe('Envelope UUID'), recipientId: z.string().describe('Recipient UUID'), documentId: z.string().optional().describe('Document UUID (required for coordinate positioning)'), type: z.enum(['signature', 'approval', 'text', 'date_of_signature', 'checkbox']).optional().describe('Tag type (default: signature)'), placeholder: z.string().optional().describe('Placeholder text to find in document (e.g. "{podpis_klient}")'), positioning: z.enum(['top_left', 'top_center', 'top_right', 'middle_left', 'center', 'middle_right', 'bottom_left', 'bottom_center', 'bottom_right']).optional().describe('How tag aligns to placeholder'), scale: z.number().optional().describe('Tag size as percentage (default 100). Use 50-80 for smaller tags.'), page: z.number().optional().describe('Page number (for coordinate positioning)'), xPosition: z.number().optional().describe('X position in points (for coordinate positioning)'), yPosition: z.number().optional().describe('Y position in points (for coordinate positioning)'), }, async ({ envelopeId, ...tagParams }) => { try { const data = await api.addTag(creds, envelopeId, tagParams); return result(data); } catch (err) { return errorResult(err); } } );