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

Function fetchFields

apps/sim/tools/jira/get_fields.ts:59–76  ·  view source on GitHub ↗
(cloudId: string)

Source from the content-addressed store, hash-verified

57
58 transformResponse: async (response: Response, params?: JiraGetFieldsParams) => {
59 const fetchFields = async (cloudId: string) => {
60 const fieldsResponse = await fetch(buildFieldsUrl(cloudId), {
61 method: 'GET',
62 headers: {
63 Accept: 'application/json',
64 Authorization: `Bearer ${params!.accessToken}`,
65 },
66 })
67
68 if (!fieldsResponse.ok) {
69 const errorText = await fieldsResponse.text()
70 throw new Error(
71 parseAtlassianErrorMessage(fieldsResponse.status, fieldsResponse.statusText, errorText)
72 )
73 }
74
75 return fieldsResponse.json()
76 }
77
78 let data: any
79

Callers 1

get_fields.tsFile · 0.85

Calls 3

buildFieldsUrlFunction · 0.85
textMethod · 0.80

Tested by

no test coverage detected