Miscellaneous Call Information for GrowthZone.
Description
This is just a catch all for Misc Stuff I have found on API Call information.
Index
- Upload Files
- b
- c
- d
Upload Files
POST /api/images/Upload/{ObjectId}/{ContactId}
Body is set to Form-data and then you include the file you are uploading
ObjectId is always set to 1 as far as I can tell but still looking into that.
ContactId is taken from
/api/contacts
https://app.screencast.com/S8wWsWc8Odf0o
API docs for this (that are pretty sparse on this ) here
https://documentation.growthzoneapp.com/Images.html#/definitions/ImageModel
CURL looks like this
curl --location 'https://paulschmalenbergtest2.growthzoneapp.com/api/images/Upload/1/72888' \
--header 'authorization: ApiKey rrGcLXExUOxqYxUxmBQxfkMVkG7XxZBNnFAmGmdA' \
--form '=@"/C:/Users/pschmalenberg/OneDrive - GrowthZone/Desktop/Chilli Reaper logo.png"'
You can edit an image using this call
POST /api/images/Image/{ImageId}
then in the body you add your own JSON in this format
{
"ImageId": "integer",
"FileId": "integer",
"ImageUsageId": "string",
"SourceType": "string",
"SourceId": "integer",
"Url": "string",
"CropX": "integer",
"CropY": "integer",
"CropHeight": "string",
"CropWidth": "string",
"ForceAspect": "string",
"Caption": "string",
"ShortDescription": "string"
}
Or a filled out example
{
"ImageId": 0,
"FileId": 30571280,
"CropX": 40,
"CropY": 26,
"CropWidth": 265,
"CropHeight": 119,
"Caption": null,
"ShortDescription": "TestAltText",
"ForceAspect": null,
"SourceType": "OrganizationImages",
"SourceId": 72887,
"ImageUsageId": 1
}