class GdsApi::AssetManager
def create_whitehall_asset(asset)
- Example: Upload a file from a Rails param, (typically a multipart wrapper) -
Example: Upload a file from disk -
Raises:
-
(HTTPErrorResponse)
- if the request returns an error
Returns:
-
(GdsApi::Response)
- The wrapped http response from the api. Behaves
Parameters:
-
asset
(Hash
) -- The attributes for the asset to send to the api. Must
def create_whitehall_asset(asset) post_multipart("#{base_url}/whitehall_assets", asset: asset) end