@mcp-z/mcp-pdf
Preparing search index...
mcp
toolFactories
pdfLayout
Function pdfLayout
pdfLayout
()
:
{
config
:
{
description
:
"Create a PDF with precise positioning using Yoga flexbox layout.\n\nBest for: Dashboards, slides, certificates, flyers, and designs requiring exact placement.\n\nAll items are positioned absolutely on specific pages. Use the \"page\" property to target different pages (e.g., page: 2 for multi-slide presentations). Pages are created as needed.\n\nUse groups for flexbox containers - they support direction, gap, justify, alignItems, and alignment properties for sophisticated layouts.\n\nDefault margins: 0 (full canvas access for precise positioning)."
;
inputSchema
:
ZodObject
<
{
author
:
ZodOptional
<
ZodString
>
;
color
:
ZodOptional
<
ZodObject
<
{
background
:
ZodOptional
<
ZodString
>
;
hyperlink
:
ZodOptional
<
ZodString
>
;
}
,
$strip
,
>
,
>
;
content
:
ZodArray
<
ZodUnion
<
readonly
[
ZodUnion
<
readonly
[
ZodObject
<
{
bold
:
...
;
characterSpacing
:
...
;
color
:
...
;
continued
:
...
;
fontSize
:
...
;
indent
:
...
;
left
:
...
;
lineBreak
:
...
;
lineGap
:
...
;
link
:
...
;
moveDown
:
...
;
oblique
:
...
;
page
:
...
;
paragraphGap
:
...
;
position
:
...
;
strike
:
...
;
text
:
...
;
textAlign
:
...
;
top
:
...
;
type
:
...
;
underline
:
...
;
width
:
...
;
wordSpacing
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
bold
:
...
;
characterSpacing
:
...
;
color
:
...
;
continued
:
...
;
fontSize
:
...
;
indent
:
...
;
left
:
...
;
lineBreak
:
...
;
lineGap
:
...
;
link
:
...
;
moveDown
:
...
;
oblique
:
...
;
page
:
...
;
paragraphGap
:
...
;
position
:
...
;
strike
:
...
;
text
:
...
;
textAlign
:
...
;
top
:
...
;
type
:
...
;
underline
:
...
;
width
:
...
;
wordSpacing
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
height
:
...
;
imagePath
:
...
;
left
:
...
;
page
:
...
;
top
:
...
;
type
:
...
;
width
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
fillColor
:
...
;
height
:
...
;
left
:
...
;
lineWidth
:
...
;
page
:
...
;
strokeColor
:
...
;
top
:
...
;
type
:
...
;
width
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
fillColor
:
...
;
left
:
...
;
lineWidth
:
...
;
page
:
...
;
radius
:
...
;
strokeColor
:
...
;
top
:
...
;
type
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
lineWidth
:
...
;
page
:
...
;
strokeColor
:
...
;
type
:
...
;
x1
:
...
;
x2
:
...
;
y1
:
...
;
y2
:
...
;
}
,
$strip
,
>
,
]
,
>
,
ZodType
<
schemas
.
GroupItem
,
unknown
,
$ZodTypeInternals
<
schemas
.
GroupItem
,
unknown
>
,
>
,
]
,
>
,
>
;
filename
:
ZodOptional
<
ZodString
>
;
font
:
ZodOptional
<
ZodString
>
;
layout
:
ZodOptional
<
ZodObject
<
{
overflow
:
ZodDefault
<
ZodOptional
<
ZodEnum
<
{
auto
:
...
;
warn
:
...
}
>
>
,
>
;
}
,
$strip
,
>
,
>
;
markdown
:
ZodOptional
<
ZodBoolean
>
;
pageSetup
:
ZodOptional
<
ZodObject
<
{
margins
:
ZodOptional
<
ZodObject
<
{
bottom
:
ZodNumber
;
left
:
ZodNumber
;
right
:
ZodNumber
;
top
:
ZodNumber
;
}
,
$strip
,
>
,
>
;
size
:
ZodOptional
<
ZodUnion
<
readonly
[
ZodEnum
<
(...)
>
,
ZodTuple
<
(...)
,
(...)
>
]
>
,
>
;
}
,
$strip
,
>
,
>
;
title
:
ZodOptional
<
ZodString
>
;
}
,
$strip
,
>
;
outputSchema
:
ZodObject
<
{
result
:
ZodObject
<
{
completedAt
:
ZodString
;
documentId
:
ZodString
;
filename
:
ZodString
;
itemsChanged
:
ZodNumber
;
itemsProcessed
:
ZodNumber
;
margins
:
ZodObject
<
{
bottom
:
ZodNumber
;
left
:
ZodNumber
;
right
:
ZodNumber
;
top
:
ZodNumber
;
}
,
$strip
,
>
;
operationSummary
:
ZodString
;
pageCount
:
ZodOptional
<
ZodNumber
>
;
sizeBytes
:
ZodNumber
;
uri
:
ZodString
;
warnings
:
ZodOptional
<
ZodArray
<
ZodString
>
>
;
}
,
$strip
,
>
;
}
,
$strip
,
>
;
title
:
"Create PDF Layout"
;
}
;
handler
:
(
args
:
{
author
?:
string
;
color
?:
{
background
?:
string
;
hyperlink
?:
string
}
;
content
:
(
|
{
bold
?:
boolean
;
characterSpacing
?:
number
;
color
?:
string
;
continued
?:
boolean
;
fontSize
?:
number
;
indent
?:
number
;
left
?:
number
;
lineBreak
?:
boolean
;
lineGap
?:
number
;
link
?:
string
;
moveDown
?:
number
;
oblique
?:
number
|
boolean
;
page
?:
number
;
paragraphGap
?:
number
;
position
?:
"absolute"
|
"relative"
;
strike
?:
boolean
;
text
?:
string
;
textAlign
?:
"center"
|
"left"
|
"right"
|
"justify"
;
top
?:
number
;
type
:
"text"
;
underline
?:
boolean
;
width
?:
number
;
wordSpacing
?:
number
;
}
|
{
bold
?:
boolean
;
characterSpacing
?:
number
;
color
?:
string
;
continued
?:
boolean
;
fontSize
?:
number
;
indent
?:
number
;
left
?:
number
;
lineBreak
?:
boolean
;
lineGap
?:
number
;
link
?:
string
;
moveDown
?:
number
;
oblique
?:
number
|
boolean
;
page
?:
number
;
paragraphGap
?:
number
;
position
?:
"absolute"
|
"relative"
;
strike
?:
boolean
;
text
?:
string
;
textAlign
?:
"center"
|
"left"
|
"right"
|
"justify"
;
top
?:
number
;
type
:
"heading"
;
underline
?:
boolean
;
width
?:
number
;
wordSpacing
?:
number
;
}
|
{
height
?:
number
;
imagePath
:
string
;
left
?:
number
;
page
?:
number
;
top
?:
number
;
type
:
"image"
;
width
?:
number
;
}
|
{
fillColor
?:
string
;
height
:
number
;
left
:
number
;
lineWidth
?:
number
;
page
?:
number
;
strokeColor
?:
string
;
top
:
number
;
type
:
"rect"
;
width
:
number
;
}
|
{
fillColor
?:
string
;
left
:
number
;
lineWidth
?:
number
;
page
?:
number
;
radius
:
number
;
strokeColor
?:
string
;
top
:
number
;
type
:
"circle"
;
}
|
{
lineWidth
?:
number
;
page
?:
number
;
strokeColor
?:
string
;
type
:
"line"
;
x1
:
number
;
x2
:
number
;
y1
:
number
;
y2
:
number
;
}
|
schemas
.
GroupItem
)
[]
;
filename
?:
string
;
font
?:
string
;
layout
?:
{
overflow
:
"auto"
|
"warn"
}
;
markdown
?:
boolean
;
pageSetup
?:
{
margins
?:
{
bottom
:
number
;
left
:
number
;
right
:
number
;
top
:
number
;
}
;
size
?:
"LETTER"
|
"A4"
|
"LEGAL"
|
[
number
?
,
number
?
,
...
unknown
[]
]
;
}
;
title
?:
string
;
}
,
extra
:
StorageExtra
,
)
=>
Promise
<
{
[
key
:
string
]:
unknown
}
>
;
name
:
string
;
}
Returns
{
config
:
{
description
:
"Create a PDF with precise positioning using Yoga flexbox layout.\n\nBest for: Dashboards, slides, certificates, flyers, and designs requiring exact placement.\n\nAll items are positioned absolutely on specific pages. Use the \"page\" property to target different pages (e.g., page: 2 for multi-slide presentations). Pages are created as needed.\n\nUse groups for flexbox containers - they support direction, gap, justify, alignItems, and alignment properties for sophisticated layouts.\n\nDefault margins: 0 (full canvas access for precise positioning)."
;
inputSchema
:
ZodObject
<
{
author
:
ZodOptional
<
ZodString
>
;
color
:
ZodOptional
<
ZodObject
<
{
background
:
ZodOptional
<
ZodString
>
;
hyperlink
:
ZodOptional
<
ZodString
>
;
}
,
$strip
,
>
,
>
;
content
:
ZodArray
<
ZodUnion
<
readonly
[
ZodUnion
<
readonly
[
ZodObject
<
{
bold
:
...
;
characterSpacing
:
...
;
color
:
...
;
continued
:
...
;
fontSize
:
...
;
indent
:
...
;
left
:
...
;
lineBreak
:
...
;
lineGap
:
...
;
link
:
...
;
moveDown
:
...
;
oblique
:
...
;
page
:
...
;
paragraphGap
:
...
;
position
:
...
;
strike
:
...
;
text
:
...
;
textAlign
:
...
;
top
:
...
;
type
:
...
;
underline
:
...
;
width
:
...
;
wordSpacing
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
bold
:
...
;
characterSpacing
:
...
;
color
:
...
;
continued
:
...
;
fontSize
:
...
;
indent
:
...
;
left
:
...
;
lineBreak
:
...
;
lineGap
:
...
;
link
:
...
;
moveDown
:
...
;
oblique
:
...
;
page
:
...
;
paragraphGap
:
...
;
position
:
...
;
strike
:
...
;
text
:
...
;
textAlign
:
...
;
top
:
...
;
type
:
...
;
underline
:
...
;
width
:
...
;
wordSpacing
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
height
:
...
;
imagePath
:
...
;
left
:
...
;
page
:
...
;
top
:
...
;
type
:
...
;
width
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
fillColor
:
...
;
height
:
...
;
left
:
...
;
lineWidth
:
...
;
page
:
...
;
strokeColor
:
...
;
top
:
...
;
type
:
...
;
width
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
fillColor
:
...
;
left
:
...
;
lineWidth
:
...
;
page
:
...
;
radius
:
...
;
strokeColor
:
...
;
top
:
...
;
type
:
...
;
}
,
$strip
,
>
,
ZodObject
<
{
lineWidth
:
...
;
page
:
...
;
strokeColor
:
...
;
type
:
...
;
x1
:
...
;
x2
:
...
;
y1
:
...
;
y2
:
...
;
}
,
$strip
,
>
,
]
,
>
,
ZodType
<
schemas
.
GroupItem
,
unknown
,
$ZodTypeInternals
<
schemas
.
GroupItem
,
unknown
>
,
>
,
]
,
>
,
>
;
filename
:
ZodOptional
<
ZodString
>
;
font
:
ZodOptional
<
ZodString
>
;
layout
:
ZodOptional
<
ZodObject
<
{
overflow
:
ZodDefault
<
ZodOptional
<
ZodEnum
<
{
auto
:
...
;
warn
:
...
}
>
>
,
>
;
}
,
$strip
,
>
,
>
;
markdown
:
ZodOptional
<
ZodBoolean
>
;
pageSetup
:
ZodOptional
<
ZodObject
<
{
margins
:
ZodOptional
<
ZodObject
<
{
bottom
:
ZodNumber
;
left
:
ZodNumber
;
right
:
ZodNumber
;
top
:
ZodNumber
;
}
,
$strip
,
>
,
>
;
size
:
ZodOptional
<
ZodUnion
<
readonly
[
ZodEnum
<
(...)
>
,
ZodTuple
<
(...)
,
(...)
>
]
>
,
>
;
}
,
$strip
,
>
,
>
;
title
:
ZodOptional
<
ZodString
>
;
}
,
$strip
,
>
;
outputSchema
:
ZodObject
<
{
result
:
ZodObject
<
{
completedAt
:
ZodString
;
documentId
:
ZodString
;
filename
:
ZodString
;
itemsChanged
:
ZodNumber
;
itemsProcessed
:
ZodNumber
;
margins
:
ZodObject
<
{
bottom
:
ZodNumber
;
left
:
ZodNumber
;
right
:
ZodNumber
;
top
:
ZodNumber
;
}
,
$strip
,
>
;
operationSummary
:
ZodString
;
pageCount
:
ZodOptional
<
ZodNumber
>
;
sizeBytes
:
ZodNumber
;
uri
:
ZodString
;
warnings
:
ZodOptional
<
ZodArray
<
ZodString
>
>
;
}
,
$strip
,
>
;
}
,
$strip
,
>
;
title
:
"Create PDF Layout"
;
}
;
handler
:
(
args
:
{
author
?:
string
;
color
?:
{
background
?:
string
;
hyperlink
?:
string
}
;
content
:
(
|
{
bold
?:
boolean
;
characterSpacing
?:
number
;
color
?:
string
;
continued
?:
boolean
;
fontSize
?:
number
;
indent
?:
number
;
left
?:
number
;
lineBreak
?:
boolean
;
lineGap
?:
number
;
link
?:
string
;
moveDown
?:
number
;
oblique
?:
number
|
boolean
;
page
?:
number
;
paragraphGap
?:
number
;
position
?:
"absolute"
|
"relative"
;
strike
?:
boolean
;
text
?:
string
;
textAlign
?:
"center"
|
"left"
|
"right"
|
"justify"
;
top
?:
number
;
type
:
"text"
;
underline
?:
boolean
;
width
?:
number
;
wordSpacing
?:
number
;
}
|
{
bold
?:
boolean
;
characterSpacing
?:
number
;
color
?:
string
;
continued
?:
boolean
;
fontSize
?:
number
;
indent
?:
number
;
left
?:
number
;
lineBreak
?:
boolean
;
lineGap
?:
number
;
link
?:
string
;
moveDown
?:
number
;
oblique
?:
number
|
boolean
;
page
?:
number
;
paragraphGap
?:
number
;
position
?:
"absolute"
|
"relative"
;
strike
?:
boolean
;
text
?:
string
;
textAlign
?:
"center"
|
"left"
|
"right"
|
"justify"
;
top
?:
number
;
type
:
"heading"
;
underline
?:
boolean
;
width
?:
number
;
wordSpacing
?:
number
;
}
|
{
height
?:
number
;
imagePath
:
string
;
left
?:
number
;
page
?:
number
;
top
?:
number
;
type
:
"image"
;
width
?:
number
;
}
|
{
fillColor
?:
string
;
height
:
number
;
left
:
number
;
lineWidth
?:
number
;
page
?:
number
;
strokeColor
?:
string
;
top
:
number
;
type
:
"rect"
;
width
:
number
;
}
|
{
fillColor
?:
string
;
left
:
number
;
lineWidth
?:
number
;
page
?:
number
;
radius
:
number
;
strokeColor
?:
string
;
top
:
number
;
type
:
"circle"
;
}
|
{
lineWidth
?:
number
;
page
?:
number
;
strokeColor
?:
string
;
type
:
"line"
;
x1
:
number
;
x2
:
number
;
y1
:
number
;
y2
:
number
;
}
|
schemas
.
GroupItem
)
[]
;
filename
?:
string
;
font
?:
string
;
layout
?:
{
overflow
:
"auto"
|
"warn"
}
;
markdown
?:
boolean
;
pageSetup
?:
{
margins
?:
{
bottom
:
number
;
left
:
number
;
right
:
number
;
top
:
number
;
}
;
size
?:
"LETTER"
|
"A4"
|
"LEGAL"
|
[
number
?
,
number
?
,
...
unknown
[]
]
;
}
;
title
?:
string
;
}
,
extra
:
StorageExtra
,
)
=>
Promise
<
{
[
key
:
string
]:
unknown
}
>
;
name
:
string
;
}
Settings
Member Visibility
Protected
Inherited
Theme
OS
Light
Dark
@mcp-z/mcp-pdf
Loading...