Skip to main content
Level 2
Sep 13, 2021 6:19 PM UTC
Question

API Documentation - How to find out max field length?

Hello,

I'm consuming the REST API for various integrations in in some cases have to store data locally. I'd like to have my DB schema match the max lengths of Marketo data but am having issues finding how to determine the max field length of various data fields returned via the API. Can anyone suggest and approach or resource to assist here?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

4 replies

Adobe Employee
Sep 13, 2021 9:45 PM UTC
SanfordWhiteman
User Group Leader
User Group Leader
Sep 13, 2021 11:45 PM UTC

The actual field limits aren’t what the Describe Lead API indicates, though it’s a start (no string is shorter that what Describe returns, at least). Unfortunately, the doc Floyd linked to isn’t completely accurate either.

 

I’ve written a few blog posts about “Marketo field limits in the real world” (you can search for that) but never had a chance to write about each and every system field + datatype. Your best bet is to use NCLOB/NVARCHAR(MAX) for strings, BigInt for scores/integers (even though they’ve recently shrunk back to Int, to my dismay) and Float64 for float/currency (even though they’re actually Float32, at some point they’re gonna have to expand so you should be prepared).

Translate
xceledAuthor
Level 2
Sep 14, 2021 2:45 PM UTC

Thank you @sanfordwhiteman for the information, I wish they would use swagger to document the response model field limits. 

 

I'm not just storing lead data, also other types, so my need is generic across any API that returns a response payload. E.g. Email subject length, folder name length, email description length.

Translate
SanfordWhiteman
User Group Leader
User Group Leader
Sep 14, 2021 3:08 PM UTC

Thank you @sanfordwhiteman for the information, I wish they would use swagger to document the response model field limits.

Wouldn’t really help if they’re not accurate! Anything that’s abstracted/manually typed instead of lifted directly from the schema can have errors. (And, historically, has.)

 


I'm not just storing lead data, also other types, so my need is generic across any API that returns a response payload. E.g. Email subject length, folder name length, email description length.

Asset names are NVARCHAR(255).

Translate