diff --git a/src/interfaces/shows-api-deletion.ts b/src/interfaces/shows-api-deletion.ts new file mode 100644 index 0000000..207da69 --- /dev/null +++ b/src/interfaces/shows-api-deletion.ts @@ -0,0 +1,4 @@ +export interface ShowsApiDeletion { + status: string + message: string +} diff --git a/src/services/shows/shows-api.service.ts b/src/services/shows/shows-api.service.ts index d2f0e2e..3ef5a39 100644 --- a/src/services/shows/shows-api.service.ts +++ b/src/services/shows/shows-api.service.ts @@ -4,6 +4,7 @@ import {Observable} from 'rxjs'; import {ShowsApiResponse} from '../../interfaces/shows-api-response'; import {ShowsApiCreation} from '../../interfaces/shows-api-creation'; import {ShowsApiIdResponse} from '../../interfaces/shows-api-id-response'; +import {ShowsApiDeletion} from '../../interfaces/shows-api-deletion'; @Injectable({ providedIn: 'root' @@ -29,4 +30,8 @@ export class ShowsApiService { sendShow(newShow: {}) { return this.http.post(this.showsEndpoint, newShow) } + + deleteShw(id: string): Observable { + return this.http.delete(this.showsEndpoint + "id/" + id) + } }