Skip to content

Commit e12e674

Browse files
committed
Merge pull request #9 from Rosenheimer/master
Removed DELETE services, change document reference services to be similar to other services
2 parents 0c94315 + e530478 commit e12e674

File tree

4 files changed

+50
-81
lines changed

4 files changed

+50
-81
lines changed

README.md

Lines changed: 34 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -33,16 +33,14 @@
3333
- [4.1.2 POST Project Services](#412-post-project-services)
3434
- [4.1.3 GET Single Project Services](#413-get-single-project-services)
3535
- [4.1.4 PUT Single Project Services](#414-put-single-project-services)
36-
- [4.1.5 DELETE Single Project Services](#415-delete-single-project-services)
37-
- [4.1.6 GET Project Extension Services](#416-get-project-extension-services)
38-
- [4.1.7 POST Project Extension Services](#417-post-project-extension-services)
39-
- [4.1.8 PUT Project Extension Services](#418-put-project-extension-services)
36+
- [4.1.5 GET Project Extension Services](#415-get-project-extension-services)
37+
- [4.1.6 POST Project Extension Services](#416-post-project-extension-services)
38+
- [4.1.7 PUT Project Extension Services](#417-put-project-extension-services)
4039
- [4.2 Topic Services](#42-topic-services)
4140
- [4.2.1 GET Topic Services](#421-get-topic-services)
4241
- [4.2.2 POST Topic Services](#422-post-topic-services)
4342
- [4.2.3 GET Single Topic Services](#423-get-single-topic-services)
4443
- [4.2.4 PUT Single Topic Services](#424-put-single-topic-services)
45-
- [4.2.5 DELETE Single Topic Services](#425-delete-single-topic-services)
4644
- [4.2.6 GET Topic BIM Snippet](#426-get-topic-bim-snippet)
4745
- [4.2.7 PUT Topic BIM Snippet](#427-put-topic-bim-snippet)
4846
- [4.3 File Services](#43-file-services)
@@ -68,13 +66,10 @@
6866
- [4.7.2 PUT Related Topics Services](#472-post-related-topics-services)
6967
- [4.8 Document Reference Services](#48-document-reference-services)
7068
- [4.8.1 GET Document Reference Services](#481-get-document-reference-services)
71-
- [4.8.2 POST Document Reference Services](#482-post-document-reference-services)
72-
- [4.8.3 GET a single Document Reference Service](#483-get-a-single-document-reference-service)
73-
- [4.8.4 PUT a single Document Reference Service](#484-put-a-single-document-reference-service)
74-
75-
76-
77-
69+
- [4.8.2 PUT Document Reference Services](#482-put-document-reference-services)
70+
- [4.9 Document Services](#49-document-services)
71+
- [4.9.1 POST Document Services](#491-post-document-services)
72+
- [4.9.2 GET Document Services](#492-get-document-services)
7873

7974

8075
----------
@@ -637,20 +632,7 @@ Retrieve a specific project.
637632
Modify a specific project, description similar to POST.
638633

639634

640-
### 4.1.5 DELETE Single Project Services ###
641-
642-
**Recource URL**
643-
644-
DELETE /bcf/{version}/projects/{project_id}
645-
646-
Delete a specific project.
647-
648-
**Example Request**
649-
650-
https://example.com/bcf/1.0/projects/B724AAC3-5B2A-234A-D143-AE33CC18414
651-
652-
653-
### 4.1.6 GET Project Extension Services ###
635+
### 4.1.5 GET Project Extension Services ###
654636

655637
**Recource URL**
656638

@@ -705,7 +687,7 @@ Retrieve a specific projects extensions.
705687
]
706688
}
707689

708-
### 4.1.7 POST Project Extension Services
690+
### 4.1.6 POST Project Extension Services
709691

710692
**Recource URL**
711693

@@ -837,7 +819,7 @@ JSON encoded body using the "application/json" content type.
837819
}
838820

839821

840-
### 4.1.8 PUT Project Extension Services
822+
### 4.1.7 PUT Project Extension Services
841823

842824
**Recource URL**
843825

@@ -1057,20 +1039,6 @@ Retrieve a specific topic.
10571039

10581040
Modify a specific topic, description similar to POST.
10591041

1060-
1061-
### 4.2.5 DELETE Single Topic Services ###
1062-
1063-
**Recource URL**
1064-
1065-
DELETE /bcf/{version}/topics/{guid}
1066-
DELETE /bcf/{version}/projects/{project_id}/topics/{guid}
1067-
1068-
Delete a specific topic
1069-
1070-
**Example Request**
1071-
1072-
https://example.com/bcf/1.0/projects/F445F4F2-4D02-4B2A-B612-5E456BEF9137/topics/B345F4F2-3A04-B43B-A713-5E456BEF8228
1073-
10741042
### 4.2.6 GET Topic BIM Snippet
10751043

10761044
**Resource URL**
@@ -2006,66 +1974,71 @@ Retrieve a **collection** of all document references to a topic.
20061974
}
20071975
]
20081976

2009-
### 4.8.2 POST Document Reference Services ###
1977+
### 4.8.2 PUT Document Reference Services ###
20101978

20111979
**Recource URL**
20121980

20131981
POST /bcf/{version}/topics/{guid}/document_references
20141982
POST /bcf/{version}/projects/{project_id}/topics/{guid}/document_references
20151983

2016-
[document_reference_POST.json](https://raw.githubusercontent.com/BuildingSMART/BCF-API/master/Schemas_draft-03/Collaboration/DocumentReference/document_reference_POST.json)
1984+
[document_reference_PUT.json](https://raw.githubusercontent.com/BuildingSMART/BCF-API/master/Schemas_draft-03/Collaboration/DocumentReference/document_reference_PUT.json)
20171985

2018-
Add a document reference to a topic.
1986+
Add or update document references to a topic.
1987+
The PUT object may either contain the property "guid" to reference a document stored on the BCF server (see section 4.9) OR the property "referenced_document" to point to an external resource.
20191988

20201989
**Example Request**
20211990

20221991
https://example.com/bcf/1.0/projects/F445F4F2-4D02-4B2A-B612-5E456BEF9137/topics/B345F4F2-3A04-B43B-A713-5E456BEF8228/document_references
20231992

1993+
[
20241994
{
20251995
"referenced_document":"http://example.com/files/LegalRequirements.pdf",
20261996
"description":"The legal requirements for buildings."
20271997
}
1998+
]
20281999

20292000
**Example Response**
20302001

2002+
[
20312003
{
20322004
"guid":"472ab37a-6122-448e-86fc-86503183b520",
20332005
"referenced_document":"http://example.com/files/LegalRequirements.pdf",
20342006
"description":"The legal requirements for buildings."
20352007
}
2008+
]
20362009

2037-
### 4.8.3 GET a single Document Reference Service ###
2010+
## 4.9 Document Services
20382011

2039-
**Recource URL**
2012+
### 4.9.1 POST Document Services
20402013

2041-
GET /bcf/{version}/document_references/{guid}
2042-
GET /bcf/{version}/projects/{project_id}/topics/{guid}/document_references/{guid}
2014+
[document_GET.json](https://raw.githubusercontent.com/BuildingSMART/BCF-API/master/Schemas_draft-03/Collaboration/Document/document_GET.json)
20432015

2044-
[document_reference_GET.json](https://raw.githubusercontent.com/BuildingSMART/BCF-API/master/Schemas_draft-03/Collaboration/DocumentReference/document_reference_GET.json)
2016+
**Recource URL**
20452017

2046-
Retrieve a single document reference.
2018+
POST /bcf/{version}/projects/{project_id}/documents
20472019

2048-
**Example Request**
2020+
Upload a document (binary file) to a project. The following HTTP headers are used for the upload:
20492021

2050-
https://example.com/bcf/1.0/projects/F445F4F2-4D02-4B2A-B612-5E456BEF9137/topics/B345F4F2-3A04-B43B-A713-5E456BEF8228/document_references/472ab37a-6122-448e-86fc-86503183b520
2022+
Content-Type: application/octet-stream;
2023+
Content-Length: {Size of file in bytes};
2024+
Content-Disposition: attachment; filename="{Filename.extension}";
20512025

20522026
**Example Response**
20532027

20542028
{
2055-
"guid":"472ab37a-6122-448e-86fc-86503183b520",
2056-
"referenced_document":"http://example.com/files/LegalRequirements.pdf",
2057-
"description":"The legal requirements for buildings."
2029+
"guid":"472ab37a-6122-448e-86fc-86503183b520"
20582030
}
20592031

2060-
### 4.8.4 PUT a single Document Reference Service ###
2032+
### 4.9.2 GET Document Services
20612033

20622034
**Recource URL**
20632035

2064-
PUT /bcf/{version}/document_references/{guid}
2065-
PUT /bcf/{version}/projects/{project_id}/topics/{guid}/document_references/{guid}
2036+
GET /bcf/{version}/projects/{project_id}/documents/{guid}
20662037

2067-
[document_reference_PUT.json](https://raw.githubusercontent.com/BuildingSMART/BCF-API/master/Schemas_draft-03/Collaboration/DocumentReference/document_reference_PUT.json)
2038+
Retrieves a document as binary file. Will use the following HTTP headers to deliver additional information:
20682039

2069-
Update a single document reference, description similar to POST.
2040+
Content-Type: application/octet-stream;
2041+
Content-Length: {Size of file in bytes};
2042+
Content-Disposition: attachment; filename="{Filename.extension}";
20702043

20712044

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"title": "document_GET",
3+
"type": "object",
4+
"properties": {
5+
"guid": {
6+
"required": true,
7+
"type": "string"
8+
}
9+
}
10+
}

Schemas_draft-03/Collaboration/DocumentReference/document_reference_POST.json

Lines changed: 0 additions & 20 deletions
This file was deleted.

Schemas_draft-03/Collaboration/DocumentReference/document_reference_PUT.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22
"title": "document_reference_PUT",
33
"type": "object",
44
"properties": {
5+
"guid": {
6+
"type": [
7+
"string",
8+
"null"
9+
]
10+
},
511
"referenced_document": {
612
"type": [
713
"string",

0 commit comments

Comments
 (0)