Skip to content

Commit

Permalink
Merge branch 'main' into APIMGMT-134-staging
Browse files Browse the repository at this point in the history
  • Loading branch information
wsocha committed Oct 16, 2023
2 parents bfd9ecb + b3f3969 commit 4b4306d
Show file tree
Hide file tree
Showing 627 changed files with 71,278 additions and 51,080 deletions.
Empty file removed -
Empty file.
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
blank_issues_enabled: false
contact_links:
- name: Box Developer Community
url: https://forum.box.com
about: Before creating an issue, I have searched the Box Developer Community and my issue isn't already reported there.
- name: Issues
url: https://github.com/box/box-openapi/issues
about: Before creating an issue, I have searched Issues in this repository and my issue isn't already reported there.
- name: API Reference
url: https://developer.box.com/reference
about: Before creating an issue, I have checked that the API documentation doesn't solve my issue.
31 changes: 31 additions & 0 deletions .github/ISSUE_TEMPLATE/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: API documentation feedback
description: Provide feedback on API documentation
labels: ["documentation"]
body:
- type: textarea
attributes:
label: Description of the issue
description: Describe what you discovered and explain why it is an issue.
validations:
required: true
- type: textarea
attributes:
label: Current content
description: What does the specification currently say?
validations:
required: false
- type: textarea
attributes:
label: Expected content
description: What should the specification say instead?
validations:
required: false
- type: input
id: url
attributes:
label: Link to the documentation page
validations:
required: false
- type: markdown
attributes:
value: "Thanks for completing our form!"
21 changes: 0 additions & 21 deletions .github/ISSUE_TEMPLATE/mistake.md

This file was deleted.

22 changes: 0 additions & 22 deletions .github/ISSUE_TEMPLATE/question.md

This file was deleted.

2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Description

Please include a summary of the change and which issue is fixed.
Please include a summary of the change and which issue is fixed.

If you are a Boxer, please also reference the related `DDOC` or `APIWG` tickets.
If you do not have a related `Jira` ticket and this is more than a bug fix, then
Expand Down
52 changes: 24 additions & 28 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ jobs:
lint:
# We run this on the latest ubuntu
runs-on: ubuntu-latest
timeout-minutes: 20
timeout-minutes: 10

# We use node 14 and Python 3.8
strategy:
matrix:
Expand All @@ -34,7 +35,7 @@ jobs:
uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

Expand All @@ -52,7 +53,7 @@ jobs:
run: |
yarn install
- name: Lint the content
- name: Lint API specification and markdown
run: |
yarn lint
Expand All @@ -61,7 +62,7 @@ jobs:
# We run this on the latest ubuntu
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
timeout-minutes: 20
timeout-minutes: 10

# We use node 14.X
strategy:
Expand All @@ -72,36 +73,37 @@ jobs:
needs:
- lint

# The following steps are performed for each lint job
# The following steps are performed for each job
steps:
- name: Check out the repo
uses: actions/checkout@v3

- name: Set up Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}

- name: Compile the content
- name: Build content
run: |
yarn install
yarn build
yarn build:spec
yarn build:content
yarn build:swagger
- name: Push compiled content
- name: Push API specification
uses: s0/git-publish-subdir-action@v2.4.0
env:
REPO: self
BRANCH: en
FOLDER: compiled/openapi
FOLDER: compiled/spec
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Push GH pages for redundancy
uses: s0/git-publish-subdir-action@v2.4.0
env:
REPO: self
BRANCH: gh-pages
FOLDER: compiled/openapi
FOLDER: compiled/content
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Push Swagger 2.0 backport
Expand Down Expand Up @@ -156,7 +158,7 @@ jobs:
# We run this on the latest ubuntu
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/staging'
timeout-minutes: 20
timeout-minutes: 10

# We use node 14.X
strategy:
Expand All @@ -167,7 +169,7 @@ jobs:
needs:
- lint

# The following steps are performed for each lint job
# The following steps are performed for each job
steps:
- name: Check out the repo
uses: actions/checkout@v3
Expand All @@ -177,17 +179,17 @@ jobs:
with:
node-version: ${{ matrix.node-version }}

- name: Compile the content
- name: Build content
run: |
yarn install
yarn build
yarn build:spec
- name: Push compiled content
- name: Push API specification
uses: s0/git-publish-subdir-action@v2.4.0
env:
REPO: self
BRANCH: en-staging
FOLDER: compiled/openapi
FOLDER: compiled/spec
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: "Trigger Netlify deployment"
Expand All @@ -214,31 +216,25 @@ jobs:
SLACK_AVATAR: "https://avatars3.githubusercontent.com/u/8659759?s=200&v=4"
with:
args: "Error running `deploy-staging` job in OpenAPI CI"

# Build the OpenAPI spec and validate using Codegen
validate-spec:
name: Validate OpenAPI spec using Codegen
# We run this on the latest ubuntu
runs-on: ubuntu-latest

# The following steps are performed for each lint job
# The following steps are performed for each job
steps:
- name: Check out the repo
uses: actions/checkout@v3
with:
path: box-openapi

- name: Set up Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: 16.x

- name: Compile the content
run: |
cd $GITHUB_WORKSPACE/box-openapi
yarn install
yarn build
- name: Check out the Codegen repo
uses: actions/checkout@v3
with:
Expand All @@ -253,5 +249,5 @@ jobs:
npm install
cd scripts
npm install
cp $GITHUB_WORKSPACE/box-openapi/compiled/openapi/openapi.json .
npm run validate ./openapi.json
cp $GITHUB_WORKSPACE/box-openapi/openapi.json .
npm run generate ./openapi.json output typescript,swift,python,c#
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ src/dev/scripts/objects/*
src/dev/index.build.js
migrate.js
compiled
yarn-error.log

#Intelij Idea
*.iml
Expand Down
3 changes: 2 additions & 1 deletion .spelling
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,5 @@ uri
url
dropdown
special
org
org
GitHub
31 changes: 12 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# Box OpenAPI 3.0 Specification

<!-- markdownlint-disable line-length -->
![CI](https://github.com/box/box-openapi/workflows/CI/badge.svg) [![Project Status](https://opensource.box.com/badges/active.svg)](http://opensource.box.com/badges)

This repository contains the build system for the Box OpenAPI 3.0 Specification
(OAS3) of the
[Box Platform API](https://developers.box.com/).
This repository contains the build system for the Box OpenAPI 3.0 Specification (OAS3) of the [Box Platform API](https://developers.box.com/).

> **Note**: Due to changes in API schema development process, this repository is currently frozen. This means we are not actively contributing to the repository, apart from necessary fixes and improvements that help us to put the new process in place even faster.
You can still use the raw sources for specification available in the **Download** section.

## Downloads

Expand All @@ -13,30 +15,20 @@ specification. For a combined, resolved version please have a look at the
following builds.

[![OpenAPI (en)](https://img.shields.io/static/v1.svg?label=OpenAPI%203&message=Download&color=grey&labelColor=0361D4&style=for-the-badge&logoColor=white)](https://raw.githubusercontent.com/box/box-openapi/en/openapi.json)
[![OpenAPI (en)](https://img.shields.io/static/v1.svg?label=OpenAPI%203&message=ダウンロード&color=grey&labelColor=0361D4&style=for-the-badge&logoColor=white)](https://raw.githubusercontent.com/box/box-openapi/jp/openapi.json)
[![OpenAPI (jp)](https://img.shields.io/static/v1.svg?label=OpenAPI%203&message=ダウンロード&color=grey&labelColor=0361D4&style=for-the-badge&logoColor=white)](https://raw.githubusercontent.com/box/box-openapi/jp/openapi.json)

[![Swagger (en)](https://img.shields.io/static/v1.svg?label=Swagger%202&message=Backported&color=grey&labelColor=0361D4&style=for-the-badge)](https://github.com/box/box-openapi/tree/swagger-2.0)
[![Swagger (en)](https://img.shields.io/static/v1.svg?label=Swagger%202&message=Legacy%20/%20Incomplete&color=grey&labelColor=lightgrey&style=for-the-badge)](https://github.com/box/box-openapi/tree/legacy-swagger-2.0/v2.0)
[![Swagger (jp)](https://img.shields.io/static/v1.svg?label=Swagger%202&message=Legacy%20/%20Incomplete&color=grey&labelColor=lightgrey&style=for-the-badge)](https://github.com/box/box-openapi/tree/legacy-swagger-2.0/v2.0)

## Swagger 2.0

The older and incomplete Swagger 2.0 specification is still available on the
[Swagger 2.0](https://github.com/box/box-openapi/tree/swagger_2.0) branch.

## Development & Contribution
[Swagger 2.0](https://github.com/box/box-openapi/tree/legacy-swagger-2.0/v2.0) branch.

Please follow the [contribution guidelines](./CONTRIBUTING.md) when contributing
to the source of this project.
## Contribution

1. [Installation & setup](./docs/index.md)
1. [Notes for Box employees](./docs/boxers.md)
1. [The OpenAPI structure and custom attributes](./docs/structure.md)
1. [Adding a new API resource](./docs/add-resource.md)
1. [Base, mini, standard, and full API resources](./docs/variants.md)
1. [Adding a new API endpoint](./docs/add-endpoint.md)
1. [Contributing a pull request](./docs/pull-request.md)
1. [Markdown styleguide](./docs/markdown.md)
1. [Updating dependencies](./docs/dependencies.md)
* If you notice that the content requires improvements or you feel that some information is missing add a new [GitHub issue](https://github.com/box/box-openapi/issues) and describe the issue.
* If you are a Boxer, create a Developer Documentation ticket or use the `#dev-docs-feedback` Slack channel for assistance.

## Usage & License

Expand All @@ -50,3 +42,4 @@ Unless required by applicable law or agreed to in writing, software distributed
under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
CONDITIONS OF ANY KIND, either express or implied. See the License for the
specific language governing permissions and limitations under the License.
<!-- markdownlint-enable line-length -->
37 changes: 0 additions & 37 deletions content/attributes/access_token--embedded.yml

This file was deleted.

Loading

0 comments on commit 4b4306d

Please sign in to comment.