One Degree Housing API

Housing properties.

Documentation

Specifications

Other Resources

OpenAPI Specification

one-degree-housing-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: One Degree Resource Server Housing API
  description: The One Degree Resource Server API provides read access to a curated database of social-service community resources — organizations and the opportunities (programs/services) they offer, along with locations, phones, schedules, ratings, tags, comments, images, properties, guides, and housing properties. One Degree is a California 501(c)(3) nonprofit; the API supports interoperability with third-party services to improve coordination and delivery of social services. Data is licensed CC BY-NC 4.0. All requests require an api_key query parameter; write verbs (POST/PUT/DELETE) additionally require HMAC-SHA256 request signatures via the 1deg-Date and 1deg-Signature headers.
  version: 1.0.0
  contact:
    name: One Degree
    url: https://about.1degree.org/contact-us/
  license:
    name: CC BY-NC 4.0
    url: https://creativecommons.org/licenses/by-nc/4.0/
  x-api-evangelist-derived-from: https://github.com/1deg/resource-server-api-docs (Postman collection + docs)
servers:
- url: https://data.1degree.org/v1
  description: Production
security:
- apiKeyAuth: []
tags:
- name: Housing
  description: Housing properties.
paths:
  /housing_properties:
    get:
      operationId: listHousingProperties
      summary: List and search housing properties
      tags:
      - Housing
      parameters:
      - $ref: '#/components/parameters/page'
      - $ref: '#/components/parameters/per_page'
      - $ref: '#/components/parameters/titles_only'
      - $ref: '#/components/parameters/ids'
      - $ref: '#/components/parameters/query_text'
      - $ref: '#/components/parameters/query_tags'
      - $ref: '#/components/parameters/query_lat'
      - $ref: '#/components/parameters/query_long'
      - $ref: '#/components/parameters/query_distance'
      - $ref: '#/components/parameters/query_order'
      - $ref: '#/components/parameters/query_match'
      responses:
        '200':
          description: Successful response (JSON by default; append .xml for XML)
          content:
            application/json:
              schema:
                type: object
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '500':
          $ref: '#/components/responses/ServerError'
components:
  responses:
    ServerError:
      description: Internal Server Error — a problem occurred at the server.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            status: error
            error: Internal server error.
    Forbidden:
      description: Forbidden — the client is not allowed to perform the requested action.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            status: error
            error: Forbidden.
    Unauthorized:
      description: Unauthorized — invalid API key or request signature.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            status: error
            error: Invalid API key or signature.
    BadRequest:
      description: Bad Request — something was wrong with the request, often a missing API key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            status: error
            error: Missing API key.
    NotFound:
      description: Not Found — nothing at the requested endpoint.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            status: error
            error: Not found.
  parameters:
    query_match:
      name: query[match]
      in: query
      required: false
      description: 'Match logic: any, properties, or by_type.'
      schema:
        type: string
      example: by_type
    per_page:
      name: per_page
      in: query
      required: false
      description: Number of items to return. Default is 10.
      schema:
        type: integer
      example: 10
    titles_only:
      name: titles_only
      in: query
      required: false
      description: Return only titles/basic info instead of full resource objects.
      schema:
        type: boolean
      example: true
    query_distance:
      name: query[distance]
      in: query
      required: false
      description: Radius in kilometers around the coordinates to search within.
      schema:
        type: number
      example: 40.2336
    page:
      name: page
      in: query
      required: false
      description: The page offset. Default is 1.
      schema:
        type: integer
      example: 3
    query_text:
      name: query[text]
      in: query
      required: false
      description: Full-text search keywords. Surround in quotes for exact phrase.
      schema:
        type: string
      example: health clinic
    query_long:
      name: query[long]
      in: query
      required: false
      description: Longitude around which to search.
      schema:
        type: number
      example: -122.46
    query_order:
      name: query[order]
      in: query
      required: false
      description: Ordering of results (default scored by best match, distance and other factors).
      schema:
        type: string
    ids:
      name: ids
      in: query
      required: false
      description: Comma-separated set of IDs whose records will be returned.
      schema:
        type: string
      example: 3,49,2
    query_tags:
      name: query[tags]
      in: query
      required: false
      description: Classification tags associated with opportunities.
      schema:
        type: string
      example: Childcare
    query_lat:
      name: query[lat]
      in: query
      required: false
      description: Latitude around which to search.
      schema:
        type: number
      example: 37.7823
  schemas:
    Error:
      type: object
      properties:
        status:
          type: string
          example: error
        error:
          type: string
          example: Missing API key.
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: query
      name: api_key
      description: All requests require an api_key query parameter. Request a key at http://socialservicedata.org/api/get-key/