MCPcopy Index your code
hub / github.com/simstudioai/sim / mapActionCardTarget

Function mapActionCardTarget

apps/sim/tools/trello/shared.ts:99–111  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

97}
98
99function mapActionCardTarget(value: unknown): TrelloActionCardTarget | null {
100 if (!isRecordLike(value) || typeof value.id !== 'string' || typeof value.name !== 'string') {
101 return null
102 }
103
104 return {
105 id: value.id,
106 name: value.name,
107 shortLink: getOptionalString(value.shortLink),
108 idShort: getOptionalNumber(value.idShort),
109 due: getOptionalString(value.due),
110 }
111}
112
113function mapActionBoardTarget(value: unknown): TrelloActionBoardTarget | null {
114 if (!isRecordLike(value) || typeof value.id !== 'string' || typeof value.name !== 'string') {

Callers 1

mapTrelloActionFunction · 0.85

Calls 3

isRecordLikeFunction · 0.90
getOptionalStringFunction · 0.85
getOptionalNumberFunction · 0.85

Tested by

no test coverage detected