Get Estate images published on Homepage

Resource type: estatepictures

With this API call, information about the images published on the own website can be read out. These are all files of the file type “pictures” in an estate, which have the check mark “own homepage / API” set under “Publication / Veröffentlichung”. If you use the multi-language module, you can read the file title and the free text field of the file language-dependent.

Further information on the multi-language module is available here.

Parameters:

  • estateids
    ARRAY. MANDATORY. estate IDs
  • categories
    ARRAY. MANDATORY. Type of File (“Titelbild”, “Foto”, “Foto_gross”, “Grundriss”, “Lageplan”, “Epass_Skala”, “Panorama”, “Link”, “Film-Link”, “Ogulo-Link”, “Objekt-Link”, “Expose”)
  • size
    STRING. OPTIONAL. The image size can be specified in pixels, e.g. 500x500. The maximum resolution that can be output here is the resolution set under “Extras >> Settings >> Basic settings >> Image format”. If you use larger values or omit the parameter, the response will return the image in the saved resolution. If “Save images in higher quality” is enabled in the basic settings, this can be queried via “size”: “original” (note that watermarks are not embedded in the higher quality images).
  • language
    STRING. OPTIONAL. Language in three capital letters according to ISO 3166-1 alpha-3. Only relevant when working with multilingual objects. For multilingual objects, file title and free text are output in the specified language. If this parameter is not specified, the file title and free text of the estate are output in the system language. If file titles and/or free text are not available in the specified language, the system language will also be output. For this parameter to work, the estateids of a main property must be specified.

Response:

  • id
    File ID
  • estateid
    Estate ID
  • type
    Type of file
  • url
    URL
  • titel
    Title
  • text
    Image description
  • modified
    Date of last change as unix timestamp
  • estateMainId
    Main estate ID.

Example with ID of a main property and specifying language:

    {
        "actionid": "urn:onoffice-de-ns:smart:2.5:smartml:action:get",
        "identifier": "",
        "resourcetype": "estatepictures",
        "resourceid": "",
        "parameters":
        {
            "estateids": [137],
            "categories": ["Foto"],
            "size":"original",
            "language":"ENG"
        }
    }

Response Example with ID of a main property and specifying language:

...
"records": [
	{
		"id": 1461,
		"type": "files",
		"elements": 
		{
			"estateid": "137",
			"type": "Foto",
			"url": "https:\/\/image.onoffice.de\/smart25\/Objekte\/index.php?kunde=Igelmund&datensatz=137&filename=Foto_1461.jpg",
			"title": "Screenshot Englisch ",
			"text": "Freitext Englisch OFF",
			"originalname": "Screenshot Shopping Center.png",
			"modified": 1540301235, 
			"estateMainId": "2591"
		}
	}
]
...

Example with ID of a property in foreign language, without specification of language:

    {
        "actionid": "urn:onoffice-de-ns:smart:2.5:smartml:action:get",
        "identifier": "",
        "resourcetype": "estatepictures",
        "resourceid": "",
        "parameters":
        {
            "estateids": [143],
            "categories": ["Foto"]
        }
    }

Response example with ID of a main property:

...
"records": [
	{
		"id": 1461,
		"type": "files",
		"elements":
		{
			"estateid": "137",
			"type": "Foto",
			"url": "https:\/\/image.onoffice.de\/smart25\/Objekte\/index.php?kunde=Igelmund&datensatz=137&filename=Foto_1461.jpg",
			"title": "Screenshot Deutsch",
			"text": "Freitext Deutsch OFF",
			"originalname": "Screenshot Shopping Center.png"
		}, 
		{
			"estateid": "143",
			"type": "Foto",
			"url": "https:\/\/image.onoffice.de\/smart25\/Objekte\/index.php?kunde=Igelmund&datensatz=137&filename=Foto_1461.jpg",
			"title": "Screenshot Englisch",
			"text": "Freitext Englisch OFF",
			"originalname": "Screenshot Shopping Center.png",
			"modified": 1540301235,
			"estateMainId": "143"
		}
	}
]
...