Skip to content

Commit

Permalink
[CCTRI-3125] remove unused endpoints (#49)
Browse files Browse the repository at this point in the history
  • Loading branch information
mstoro authored Nov 5, 2021
1 parent 834abee commit dcea69a
Show file tree
Hide file tree
Showing 6 changed files with 0 additions and 58 deletions.
6 changes: 0 additions & 6 deletions code/api/enrich.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,6 @@
get_observables = partial(get_json, schema=ObservableSchema(many=True))


@enrich_api.route('/deliberate/observables', methods=['POST'])
def deliberate_observables():
# There are no verdicts to extract.
return jsonify_data({})


@enrich_api.route('/observe/observables', methods=['POST'])
def observe_observables():
input_observables = get_observables()
Expand Down
17 changes: 0 additions & 17 deletions code/api/respond.py

This file was deleted.

2 changes: 0 additions & 2 deletions code/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

from api.enrich import enrich_api
from api.health import health_api
from api.respond import respond_api
from api.version import version_api
from api.watchdog import watchdog_api

Expand All @@ -16,7 +15,6 @@

app.register_blueprint(health_api)
app.register_blueprint(enrich_api)
app.register_blueprint(respond_api)
app.register_blueprint(version_api)
app.register_blueprint(watchdog_api)

Expand Down
1 change: 0 additions & 1 deletion code/tests/unit/api/test_enrich.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ def avotx_api_route(request):


def all_routes():
yield '/deliberate/observables'
yield '/observe/observables'
yield '/refer/observables'

Expand Down
29 changes: 0 additions & 29 deletions code/tests/unit/api/test_respond.py

This file was deleted.

3 changes: 0 additions & 3 deletions code/tests/unit/test_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,8 @@ def calls():
yield Call('DELETE', '/delete', HTTPStatus.NOT_FOUND)

yield Call('GET', '/health', HTTPStatus.METHOD_NOT_ALLOWED)
yield Call('GET', '/deliberate/observables', HTTPStatus.METHOD_NOT_ALLOWED)
yield Call('GET', '/observe/observables', HTTPStatus.METHOD_NOT_ALLOWED)
yield Call('GET', '/refer/observables', HTTPStatus.METHOD_NOT_ALLOWED)
yield Call('GET', '/respond/observables', HTTPStatus.METHOD_NOT_ALLOWED)
yield Call('GET', '/respond/trigger', HTTPStatus.METHOD_NOT_ALLOWED)
yield Call('GET', '/version', HTTPStatus.METHOD_NOT_ALLOWED)
yield Call('POST', '/watchdog', HTTPStatus.METHOD_NOT_ALLOWED)

Expand Down

0 comments on commit dcea69a

Please sign in to comment.