Procore.Api.CoreProjectProjectUploads (procore_sdk v0.3.0)
API calls for all endpoints tagged CoreProjectProjectUploads
.
Summary
Functions
Create Upload Creating an Upload is the first step in associating a file to a resource in Procore. Creating an Upload can be seen as fetching instruction on how to post your file directly to Procore's storage service. The instructions contain three properties: a UUID to reference the Upload, a URL which has to be used to post the file, and fields which need to be posted together with the file. To upload the file you must POST to the URL in the url property with a multipart/form-data body (see RFC 2388). Make sure to include all the names and values from fields without altering them. The URL and fields necessary to complete the upload may vary between companies and may also change over time so none of these may be hard-coded. Finally add a field named file with the actual file data. Uploads are associated to the Company that owns the project so they can use company specific upload settings. The currently authenticated user will become the owner of the Upload and only that user can use the Upload in subsequent requests. You will have to initiate the upload within one hour or you can expect a 403 Forbidden response. Other errors are usually clearly explained in the response body. For an example of how to associate a finalized upload to another resource in Procore see the Photos resource. An Upload will have to be associated to another resource within a week or it will be automatically deleted from Procore servers. Note that there is also a variant of this API endpoint that works using a Company ID.
Show Upload Show detailed information on an upload
Update Upload Update the upload.
Create Upload Creating an Upload is the first step in associating a file to a resource in Procore. Creating an Upload can be seen as fetching instruction on how to post your file directly to Procore's storage service. The instructions contain three properties: a UUID to reference the Upload, a URL which has to be used to post the file, and fields which need to be posted together with the file. To upload the file you must POST to the URL in the url property with a multipart/form-data body (see RFC 2388). Make sure to include all the names and values from fields without altering them. The URL and fields necessary to complete the upload may vary between companies and may also change over time so none of these may be hard-coded. Finally add a field named file with the actual file data. Uploads are associated to the Company that owns the project so they can use company specific upload settings. The currently authenticated user will become the owner of the Upload and only that user can use the Upload in subsequent requests. You will have to initiate the upload within one hour or you can expect a 403 Forbidden response. Other errors are usually clearly explained in the response body. For an example of how to associate a finalized upload to another resource in Procore see the Photos resource. An Upload will have to be associated to another resource within a week or it will be automatically deleted from Procore servers. Note that there is also a variant of this API endpoint that works using a Company ID.
Show Upload Show detailed information on an upload
Update Upload Update the upload.
Functions
rest_v10_projects_project_id_uploads_post(connection, procore_company_id, project_id, opts \\ [])
@spec rest_v10_projects_project_id_uploads_post( Tesla.Env.client(), integer(), integer(), keyword() ) :: {:ok, Procore.Model.RestV10CompaniesCompanyIdWorkflowPermanentLogsGet401Response.t()} | {:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t()} | {:error, Tesla.Env.t()}
Create Upload Creating an Upload is the first step in associating a file to a resource in Procore. Creating an Upload can be seen as fetching instruction on how to post your file directly to Procore's storage service. The instructions contain three properties: a UUID to reference the Upload, a URL which has to be used to post the file, and fields which need to be posted together with the file. To upload the file you must POST to the URL in the url property with a multipart/form-data body (see RFC 2388). Make sure to include all the names and values from fields without altering them. The URL and fields necessary to complete the upload may vary between companies and may also change over time so none of these may be hard-coded. Finally add a field named file with the actual file data. Uploads are associated to the Company that owns the project so they can use company specific upload settings. The currently authenticated user will become the owner of the Upload and only that user can use the Upload in subsequent requests. You will have to initiate the upload within one hour or you can expect a 403 Forbidden response. Other errors are usually clearly explained in the response body. For an example of how to associate a finalized upload to another resource in Procore see the Photos resource. An Upload will have to be associated to another resource within a week or it will be automatically deleted from Procore servers. Note that there is also a variant of this API endpoint that works using a Company ID.
Parameters
connection
(Procore.Connection): Connection to serverprocore_company_id
(integer()): Unique company identifier associated with the Procore User Account.project_id
(integer()): Unique identifier for the project.opts
(keyword): Optional parameters:response_filename
(String.t): By setting a filename you ensure that the storage service knows the filename of the upload. Files are often downloaded directly from the storage service and without the filename they will save on the end users' device without a readable name or extension. Setting this parameter is optional but highly recommended.:response_content_type
(String.t): The content-type set through this parameter will be used by the storage service during download just like the response_filename. Setting this value is less important because HTTP clients and operating systems are generally well equipped to determine file types. Setting this parameter is optional and should only be included when you are certain it's correct or when you want to force a content-type other than what the filename extension suggests.:attachment_content_disposition
(boolean()): The content type set through this parameter will be used by the storage system during download, similar to the response_filename. When set to true, the file will be downloaded as an attachment. Otherwise, the file content will be rendered inline in the browser.:size
(integer()): File size in bytes:segments
([Procore.Model.UploadSegmentsInner.t]): Upload segments
Returns
{:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t}
on success{:error, Tesla.Env.t}
on failure
rest_v10_projects_project_id_uploads_uuid_get(connection, procore_company_id, project_id, uuid, opts \\ [])
@spec rest_v10_projects_project_id_uploads_uuid_get( Tesla.Env.client(), integer(), integer(), String.t(), keyword() ) :: {:ok, Procore.Model.RestV10CompaniesCompanyIdWorkflowPermanentLogsGet401Response.t()} | {:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t()} | {:error, Tesla.Env.t()}
Show Upload Show detailed information on an upload
Parameters
connection
(Procore.Connection): Connection to serverprocore_company_id
(integer()): Unique company identifier associated with the Procore User Account.project_id
(integer()): Unique identifier for the project.uuid
(String.t): Upload UUIDopts
(keyword): Optional parameters
Returns
{:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t}
on success{:error, Tesla.Env.t}
on failure
rest_v10_projects_project_id_uploads_uuid_patch(connection, procore_company_id, project_id, uuid, opts \\ [])
@spec rest_v10_projects_project_id_uploads_uuid_patch( Tesla.Env.client(), integer(), integer(), String.t(), keyword() ) :: {:ok, Procore.Model.RestV10CompaniesCompanyIdWorkflowPermanentLogsGet401Response.t()} | {:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t()} | {:error, Tesla.Env.t()}
Update Upload Update the upload.
Parameters
connection
(Procore.Connection): Connection to serverprocore_company_id
(integer()): Unique company identifier associated with the Procore User Account.project_id
(integer()): Unique identifier for the project.uuid
(String.t): Upload UUIDopts
(keyword): Optional parameters:body
(Upload1):
Returns
{:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t}
on success{:error, Tesla.Env.t}
on failure
rest_v11_projects_project_id_uploads_post(connection, procore_company_id, project_id, response_filename, opts \\ [])
@spec rest_v11_projects_project_id_uploads_post( Tesla.Env.client(), integer(), integer(), String.t(), keyword() ) :: {:ok, Procore.Model.RestV10CompaniesCompanyIdWorkflowPermanentLogsGet401Response.t()} | {:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t()} | {:error, Tesla.Env.t()}
Create Upload Creating an Upload is the first step in associating a file to a resource in Procore. Creating an Upload can be seen as fetching instruction on how to post your file directly to Procore's storage service. The instructions contain three properties: a UUID to reference the Upload, a URL which has to be used to post the file, and fields which need to be posted together with the file. To upload the file you must POST to the URL in the url property with a multipart/form-data body (see RFC 2388). Make sure to include all the names and values from fields without altering them. The URL and fields necessary to complete the upload may vary between companies and may also change over time so none of these may be hard-coded. Finally add a field named file with the actual file data. Uploads are associated to the Company that owns the project so they can use company specific upload settings. The currently authenticated user will become the owner of the Upload and only that user can use the Upload in subsequent requests. You will have to initiate the upload within one hour or you can expect a 403 Forbidden response. Other errors are usually clearly explained in the response body. For an example of how to associate a finalized upload to another resource in Procore see the Photos resource. An Upload will have to be associated to another resource within a week or it will be automatically deleted from Procore servers. Note that there is also a variant of this API endpoint that works using a Company ID.
Parameters
connection
(Procore.Connection): Connection to serverprocore_company_id
(integer()): Unique company identifier associated with the Procore User Account.project_id
(integer()): Unique identifier for the project.response_filename
(String.t): By setting a filename you ensure that the storage service knows the filename of the upload. Files are often downloaded directly from the storage service and without the filename they will save on the end users' device without a readable name or extension.opts
(keyword): Optional parameters:response_content_type
(String.t): The content-type set through this parameter will be used by the storage service during download just like the response_filename. Setting this value is less important because HTTP clients and operating systems are generally well equipped to determine file types. Setting this parameter is optional and should only be included when you are certain it's correct or when you want to force a content-type other than what the filename extension suggests.:attachment_content_disposition
(boolean()): The content type set through this parameter will be used by the storage system during download, similar to the response_filename. When set to true, the file will be downloaded as an attachment. Otherwise, the file content will be rendered inline in the browser.:size
(integer()): File size in bytes:segments
([Procore.Model.UploadSegmentsInner.t]): Upload segments
Returns
{:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t}
on success{:error, Tesla.Env.t}
on failure
rest_v11_projects_project_id_uploads_uuid_get(connection, procore_company_id, project_id, uuid, opts \\ [])
@spec rest_v11_projects_project_id_uploads_uuid_get( Tesla.Env.client(), integer(), integer(), String.t(), keyword() ) :: {:ok, Procore.Model.RestV10CompaniesCompanyIdWorkflowPermanentLogsGet401Response.t()} | {:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t()} | {:error, Tesla.Env.t()}
Show Upload Show detailed information on an upload
Parameters
connection
(Procore.Connection): Connection to serverprocore_company_id
(integer()): Unique company identifier associated with the Procore User Account.project_id
(integer()): Unique identifier for the project.uuid
(String.t): Upload UUIDopts
(keyword): Optional parameters
Returns
{:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t}
on success{:error, Tesla.Env.t}
on failure
rest_v11_projects_project_id_uploads_uuid_patch(connection, procore_company_id, project_id, uuid, opts \\ [])
@spec rest_v11_projects_project_id_uploads_uuid_patch( Tesla.Env.client(), integer(), integer(), String.t(), keyword() ) :: {:ok, Procore.Model.RestV10CompaniesCompanyIdWorkflowPermanentLogsGet401Response.t()} | {:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t()} | {:error, Tesla.Env.t()}
Update Upload Update the upload.
Parameters
connection
(Procore.Connection): Connection to serverprocore_company_id
(integer()): Unique company identifier associated with the Procore User Account.project_id
(integer()): Unique identifier for the project.uuid
(String.t): Upload UUIDopts
(keyword): Optional parameters:body
(Upload1):
Returns
{:ok, Procore.Model.RestV11ProjectsProjectIdUploadsPost201Response.t}
on success{:error, Tesla.Env.t}
on failure